rewrite.markAsRemoved(arg1);
rewrite.markAsRemoved(arg1, null);
	public void testSuperMethodInvocation() throws Exception {		IPackageFragment pack1= fSourceFolder.createPackageFragment("test1", false, null);		StringBuffer buf= new StringBuffer();		buf.append("package test1;\n");		buf.append("public class E {\n");		buf.append("    public void foo() {\n");		buf.append("        super.foo();\n");		buf.append("        Outer.super.foo(i);\n");				buf.append("        Outer.super.foo(foo(X.goo()), 1);\n");		buf.append("    }\n");		buf.append("}\n");			ICompilationUnit cu= pack1.createCompilationUnit("E.java", buf.toString(), false, null);				CompilationUnit astRoot= createAST(cu);		NewASTRewrite rewrite= new NewASTRewrite(astRoot.getAST());				AST ast= astRoot.getAST();				assertTrue("Parse errors", (astRoot.getFlags() & ASTNode.MALFORMED) == 0);		TypeDeclaration type= findTypeDeclaration(astRoot, "E");				MethodDeclaration methodDecl= findMethodDeclaration(type, "foo");		Block block= methodDecl.getBody();		List statements= block.statements();		assertTrue("Number of statements not 3", statements.size() == 3);		{ // add qualifier & parameter			ExpressionStatement statement= (ExpressionStatement) statements.get(0);			SuperMethodInvocation invocation= (SuperMethodInvocation) statement.getExpression();			SimpleName newExpression= ast.newSimpleName("X");			rewrite.markAsInsert(invocation, SuperMethodInvocation.QUALIFIER_PROPERTY, newExpression, null);						ASTNode arg= ast.newNumberLiteral("1");			rewrite.getListRewrite(invocation, SuperMethodInvocation.ARGUMENTS_PROPERTY).insertLast(arg, null);		}		{ // remove qualifier, replace argument with argument of expression			ExpressionStatement statement= (ExpressionStatement) statements.get(1);			SuperMethodInvocation invocation= (SuperMethodInvocation) statement.getExpression();			Name qualifier= invocation.getQualifier();			rewrite.markAsRemoved(qualifier);						Name placeHolder= (Name) rewrite.createCopyPlaceholder(qualifier);						FieldAccess newFieldAccess= ast.newFieldAccess();			newFieldAccess.setExpression(placeHolder);			newFieldAccess.setName(ast.newSimpleName("count"));						ASTNode arg1= (ASTNode) invocation.arguments().get(0);			rewrite.markAsReplaced(arg1, newFieldAccess);		}		{ // remove argument, replace qualifier with part argument qualifier			ExpressionStatement statement= (ExpressionStatement) statements.get(2);			SuperMethodInvocation invocation= (SuperMethodInvocation) statement.getExpression();						MethodInvocation arg1= (MethodInvocation) invocation.arguments().get(0);			rewrite.markAsRemoved(arg1);						MethodInvocation innerArg= (MethodInvocation) arg1.arguments().get(0);						ASTNode placeHolder= rewrite.createCopyPlaceholder(innerArg.getExpression());						rewrite.markAsReplaced(invocation.getQualifier(), placeHolder);		}					String preview= evaluateRewrite(cu, rewrite);				buf= new StringBuffer();		buf.append("package test1;\n");		buf.append("public class E {\n");		buf.append("    public void foo() {\n");		buf.append("        X.super.foo(1);\n");		buf.append("        super.foo(Outer.count);\n");				buf.append("        X.super.foo(1);\n");		buf.append("    }\n");		buf.append("}\n");			assertEqualString(preview, buf.toString());			}