code: public Class getTypeClass(){
          if (clazz != null) return clazz;
          if (redirect != null) return redirect.getTypeClass();
  
          ClassNode component = redirect().componentType;
          if (component!=null && component.isResolved()){
              return Array.newInstance(component.getTypeClass(), 0).getClass();
          }
          throw new GroovyBugError("ClassNode#getTypeClass for "+getName()+" is called before the type class is set ");
      }
docs: Returns the concrete class this classnode relates to. However, this method
  is inherently unsafe as it may return null depending on the compile phase you are
  using. AST transformations should never use this method directly, but rather obtain
  a new class node using {@link #getPlainNodeReference()}.
  @return the class this classnode relates to. May return null.