Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [cdt-dev] Eclipse CDT: Modify and save AST

On 26 November 2016 at 23:55, sim0s <gerasimu_s@xxxxxxxxxxx> wrote:
> Hi Jonah,
> Thanks for your advice.

No problem.

> Yes, my project is an Eclipse plugin. I restart Eclipse and everything seems
> to be working fine now. I am not quite sure what was wrong but it seems that
> refactoring is working now.
If you were live editing during a debug session, or something else
happening it is reasonable* that the OSGi classloaders may have got
out of sync.

*reasonable, but unfortunate, If you ever come across are reproducible
test case, please file a bug

> I have another question and I hope you can help: While researching how
> refactoring is implemented in CDT I came across some advice suggesting to
> implement my refactoring class (that extends CRefactoring) and to populate
> it with the following methods:
> 1. checkInitialConditions(..)
> 2. createChange()...
> 3. checkFinalConditions().

I assume you are referring to these slides:

Refactoring is the UI, undo, preview etc on top of actually doing the
changes. So if you are exposing this in the UI you probably want
CRefactoring. If you are creating a tool with some other user
interface you probably don't need CRefactoring.

> What is the difference between these two approaches? Which is the most
> preferred? And finally, is there any minimal code snippet I could use?
> Regards,
> Simos
> --
> View this message in context:
> Sent from the Eclipse CDT - Development mailing list archive at
> _______________________________________________
> cdt-dev mailing list
> cdt-dev@xxxxxxxxxxx
> To change your delivery options, retrieve your password, or unsubscribe from this list, visit

Back to the top