introducing errors in the context of automated refactoring. This is also shown
in bug\ldots \todoin{File Eclipse bug report}
+\subsection{A double class instance creation}
+The following is a problem caused solely by the underlying \MoveMethod
+refactoring. The problem occurs if two classes are instantiated such that the
+first constructor invocation is an argument to a second, and that the first
+constructor invocation takes an argument that is built up using a field. As an
+example, say that \var{name} is a field of the enclosing class, and we have the
+expression \code{new A(new B(name))}. If this expression is located in a
+selection that is moved to another class, \var{name} will be left untouched,
+instead of being prefixed with a variable of the same type as it is declared in.
+If \var{name} is the destination for the move, it is not replaced by
+\code{this}, or removed if it is a prefix to a member access
+(\code{name.member}), but it is still left by itself.
+
+Situations like this would lead to code that will not compile. Therefore, we
+have to avoid them by not allowing selections to contain such double class
+instance creations that also contains references to fields.
+\todoin{File Eclipse bug report}
+
\subsection{Instantiation of non-static inner class}
When a non-static inner class is instantiated, this must happen in the scope of
its declaring class. This is because it must have access to the members of the
package-private within the selection, and throws an
\type{IllegalExpressionFoundException} if one is found.
+\subsection{The DoubleClassInstanceCreationChecker}
+The \type{DoubleClassInstanceCreationChecker} checks that there are no double
+class instance creations where the inner constructor call take and argument that
+is built up using field references.
+
+The checker visits all nodes of type \type{ClassInstanceCreation} within a
+selection. For all of these nodes, if its parent also is a class instance
+creation, it accepts a visitor that throws a
+\type{IllegalExpressionFoundException} if it enclounters a name that is a field
+reference.
+
\subsection{The InstantiationOfNonStaticInnerClassChecker}
The \type{InstantiationOfNonStaticInnerClassChecker} checks that selections
does not contain instantiations of non-static inner classes. The