code: public static boolean isInAnnotation(Env<?> env, JCTree tree) {
          TreePath tp = TreePath.getPath(env.toplevel, tree);
          if (tp != null) {
              for (Tree t : tp) {
                  if (t.getKind() == Tree.Kind.ANNOTATION)
                      return true;
              }
          }
          return false;
      }
docs: Return true iff this tree is a child of some annotation.