System.out.println("type check local assign" );
    public Node typeCheck(TypeChecker tc) throws SemanticException {        JL5TypeSystem ts = (JL5TypeSystem)tc.typeSystem();        if (right() instanceof Call && ((JL5MethodInstance)((Call)right()).methodInstance()).isGeneric()){            if (!ts.isImplicitCastValid(right.type(), left.type()) &&                 !ts.equals(right.type(), left.type())){                // determine infered type of type vars in init type                // and update init type                List formalTypes = new ArrayList();                formalTypes.add(right.type());                List argTypes = new ArrayList();                argTypes.add(left.type());                List inferredTypes = ts.inferTypesFromArgs(((JL5MethodInstance)((Call)right()).methodInstance()).typeVariables(), formalTypes, argTypes, new ArrayList());                Type inferred = right().type();                if (right().type() instanceof IntersectionType && ((JL5MethodInstance)((Call)right()).methodInstance()).typeVariables().contains(right().type())){                    int pos = ((JL5MethodInstance)((Call)right()).methodInstance()).typeVariables().indexOf(right().type());                    inferred = (Type)inferredTypes.get(pos);                }                else if (right().type() instanceof ParameterizedType){                    inferred = ((ParameterizedType)right().type()).convertToInferred(((JL5MethodInstance)((Call)right()).methodInstance()).typeVariables(), inferredTypes);                }                if (inferred != right().type()){                    return right(((JL5Call)right()).type(inferred)).typeCheck(tc);                }            }        }            return super.typeCheck(tc);    }