Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'core/org.eclipse.cdt.ui.tests/resources/refactoring/ExtractMethod.rts')
-rw-r--r--core/org.eclipse.cdt.ui.tests/resources/refactoring/ExtractMethod.rts30
1 files changed, 29 insertions, 1 deletions
diff --git a/core/org.eclipse.cdt.ui.tests/resources/refactoring/ExtractMethod.rts b/core/org.eclipse.cdt.ui.tests/resources/refactoring/ExtractMethod.rts
index 758e2c6610..14e12ac430 100644
--- a/core/org.eclipse.cdt.ui.tests/resources/refactoring/ExtractMethod.rts
+++ b/core/org.eclipse.cdt.ui.tests/resources/refactoring/ExtractMethod.rts
@@ -1811,6 +1811,34 @@ returnvalue=false
returnparameterindex=0
visibility=public
+//!Bug 288268: c-refactoring creates c++-parameters
+//#org.eclipse.cdt.ui.tests.refactoring.extractfunction.ExtractFunctionRefactoringTest
+//@main.c
+int main()
+{
+ int a,b;
+ /*$*/a = b*2;/*$$*/
+ return a;
+}
+
+//=
+void test(int *a, int b)
+{
+ a = b * 2;
+}
+
+int main()
+{
+ int a,b;
+ test(a, b);
+ return a;
+}
+
+//@.config
+filename=main.c
+methodname=test
+replaceduplicates=false
+returnvalue=false
//!ExtractFunctionRefactoringTest const Method Bug # 46
//#org.eclipse.cdt.ui.tests.refactoring.extractfunction.ExtractFunctionRefactoringTest
//@A.h
@@ -2766,7 +2794,7 @@ int main()
}
//=
-void exp(int b, int & a)
+void exp(int b, int *a)
{
b = a * 2;
}

Back to the top