View | Details | Raw Unified | Return to bug 130000 | Differences between
and this patch

Collapse All | Expand All

(-)model/org/eclipse/jdt/core/compiler/ReconcileContext.java (-1 / +14 lines)
Lines 118-124 Link Here
118
public boolean isResolvingBindings() {
118
public boolean isResolvingBindings() {
119
	return this.operation.resolveBindings;
119
	return this.operation.resolveBindings;
120
}
120
}
121
121
/**
122
 * Returns the reconcile flag of this context. This flag is a bitwise value of the constant defined
123
 * in {@link ICompilationUnit}.
124
 *
125
 * @return the reconcile flag of this context
126
 * @since 3.6
127
 *
128
 * @see ICompilationUnit#ENABLE_BINDINGS_RECOVERY
129
 * @see ICompilationUnit#ENABLE_STATEMENTS_RECOVERY
130
 * @see ICompilationUnit#IGNORE_METHOD_BODIES
131
 */
132
public int getReconcileFlags() {
133
	return this.operation.reconcileFlags;
134
}
122
/**
135
/**
123
 * Returns the delta describing the change to the working copy being reconciled.
136
 * Returns the delta describing the change to the working copy being reconciled.
124
 * Returns <code>null</code> if there is no change.
137
 * Returns <code>null</code> if there is no change.
(-)src/org/eclipse/jdt/core/tests/model/ReconcilerTests.java (-8 / +10 lines)
Lines 87-93 Link Here
87
		}
87
		}
88
	}
88
	}
89
89
90
/*	static class ReconcileParticipant2 extends CompilationParticipant {
90
	static class ReconcileParticipant2 extends CompilationParticipant {
91
		IJavaElementDelta delta;
91
		IJavaElementDelta delta;
92
		org.eclipse.jdt.core.dom.CompilationUnit ast;
92
		org.eclipse.jdt.core.dom.CompilationUnit ast;
93
		ReconcileParticipant2() {
93
		ReconcileParticipant2() {
Lines 100-107 Link Here
100
			this.delta = context.getDelta();
100
			this.delta = context.getDelta();
101
			try {
101
			try {
102
				this.ast = context.getAST3();
102
				this.ast = context.getAST3();
103
				assertTrue("Context should have statement recovery enabled", context.hasStatementRecovery());
103
				assertTrue("Context should have statement recovery enabled", (context.getReconcileFlags() & ICompilationUnit.ENABLE_STATEMENTS_RECOVERY) != 0);
104
				assertTrue("Context should have ignore method body enabled", context.hasIgnoreMethodBodies());
104
				assertTrue("Context should have ignore method body enabled", (context.getReconcileFlags() & ICompilationUnit.IGNORE_METHOD_BODIES) != 0);
105
			} catch (JavaModelException e) {
105
			} catch (JavaModelException e) {
106
				assertNull("Unexpected exception", e);
106
				assertNull("Unexpected exception", e);
107
			}
107
			}
Lines 121-133 Link Here
121
			this.delta = context.getDelta();
121
			this.delta = context.getDelta();
122
			try {
122
			try {
123
				this.ast = context.getAST3();
123
				this.ast = context.getAST3();
124
				assertFalse("Context should have statement recovery enabled", context.hasStatementRecovery());
124
				assertFalse("Context should have statement recovery enabled", (context.getReconcileFlags() & ICompilationUnit.ENABLE_STATEMENTS_RECOVERY) != 0);
125
				assertTrue("Context should have ignore method body enabled", context.hasIgnoreMethodBodies());
125
				assertTrue("Context should have ignore method body enabled", (context.getReconcileFlags() & ICompilationUnit.IGNORE_METHOD_BODIES) != 0);
126
			} catch (JavaModelException e) {
126
			} catch (JavaModelException e) {
127
				assertNull("Unexpected exception", e);
127
				assertNull("Unexpected exception", e);
128
			}
128
			}
129
		}
129
		}
130
	}*/
130
	}
131
/**
131
/**
132
 */
132
 */
133
public ReconcilerTests(String name) {
133
public ReconcilerTests(String name) {
Lines 4428-4434 Link Here
4428
			ast
4428
			ast
4429
		);
4429
		);
4430
}
4430
}
4431
/*public void testIgnoreMethodBodies3() throws CoreException {
4431
//https://bugs.eclipse.org/bugs/show_bug.cgi?id=130000
4432
public void testIgnoreMethodBodies3() throws CoreException {
4432
	new ReconcileParticipant2();
4433
	new ReconcileParticipant2();
4433
	setWorkingCopyContents(
4434
	setWorkingCopyContents(
4434
		"package p1;\n" +
4435
		"package p1;\n" +
Lines 4462-4467 Link Here
4462
			ast
4463
			ast
4463
		);
4464
		);
4464
}
4465
}
4466
//https://bugs.eclipse.org/bugs/show_bug.cgi?id=130000
4465
public void testIgnoreMethodBodies4() throws CoreException {
4467
public void testIgnoreMethodBodies4() throws CoreException {
4466
	new ReconcileParticipant3();
4468
	new ReconcileParticipant3();
4467
	setWorkingCopyContents(
4469
	setWorkingCopyContents(
Lines 4495-4499 Link Here
4495
			"}\n",
4497
			"}\n",
4496
			ast
4498
			ast
4497
		);
4499
		);
4498
}*/
4500
}
4499
}
4501
}

Return to bug 130000