GrTypeElement () { T stub = getStub(); if (stub != null) { return stub.getTypeElement(); } PsiElement parent = getParent(); if (parent instanceof GrVariableDeclaration) { return ((GrVariableDeclaration)parent).getTypeElementGroovyForVariable(this); } return findChildByClass(GrTypeElement.class); }