Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [cdt-dev] Performing Refactoring without GUI

I created a bug for the issue I described:
https://bugs.eclipse.org/bugs/show_bug.cgi?id=412032

Marc-Andre


From: cdt-dev-bounces@xxxxxxxxxxx [cdt-dev-bounces@xxxxxxxxxxx] on behalf of Marc-André Laperle [marc-andre.laperle@xxxxxxxxxxxx]
Sent: Monday, July 01 2013 11:30 AM
To: CDT General developers list.
Subject: Re: [cdt-dev] Performing Refactoring without GUI

Hello Gustavo,

What is the call stack when you get the exception? I noticed something different between using .c and .cpp: when using .c, a name for the extracted variable is not suggested which makes the refactoring test fail but if I use .cpp, the name 'i' is suggested and the test passes.

Marc-Andre


From: cdt-dev-bounces@xxxxxxxxxxx [cdt-dev-bounces@xxxxxxxxxxx] on behalf of Gustavo Wagner [gugawag@xxxxxxxxx]
Sent: Sunday, 30 June 2013 1:35 AM
To: cdt-dev@xxxxxxxxxxx
Subject: [cdt-dev] Performing Refactoring without GUI

Hello.

  I'm trying to perform refactoring via CDT api, using as example the ExtractLocalVariableRefactoringTest class, but after execute this class in JUnit it shows a NullPointerException. Could you show me a code example of refactoring using API, given a .c file as input and a text selection in this file? 

Example of a .c file:


int f(){

  int x = 2; //2 could be the selection

}


Thank you so much.


--
[]s,

  Gustavo

     http://www.gustavowagner.com
     Skype/Redes Sociais: gugawag

Back to the top