Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[jdt-ui-dev] Refactoring: checking compilation of multiple compilation units after the operation?

I have implemented a refactoring that may effect multiple compilation units.
I've noticed that some refactorings run a compilation on WorkingCopy's of
the affected compilation units.

1) What's the motivation for checking that the compilation has no errors?
Presumably a refactoring always produces syntactically-valid code, and
moreover doesn't change behavior (otherwise it's not really a refactoring).

2) If there is a good reason for checking compilation of the result of my
refactoring, how do I check the compilation of multiple compilation units?

My refactoring modifies the signature of a method, and so call sites in
other compilation units will generally be modified to match.

The compilation-checking code that I've seen elsewhere in jdt.ui looks
like it wouldn't work if the changes span multiple compilation units.

Thanks in advance for any and all pointers...


===================================================
Dr. Robert M. Fuhrer, rfuhrer@xxxxxxxxxxxxxx
IBM T.J. Watson Research Center



Back to the top