@Override
    public Class<?> loadClass(String name, boolean resolve) throws ClassNotFoundException {
      synchronized (getClassLoadingLock(name)) {
        Class<?> c;
        if (name.startsWith(ECLIPSE_PACKAGE_PREFIX)) {
          c = contextLoader.loadClass(name);
        } else {
          c = findLoadedClass(name);
          if (c == null) {
            try {
              c = findClass(name);
            } catch (ClassNotFoundException ex) {
              return super.loadClass(name, resolve);
            }
          }
        }
        if (resolve) {
          resolveClass(c);
        }
        return c;
      }
    }
We find the delegating classloader by traversing the call stack and looking for the first
class that has a classloader from the Eclipse namespace. This is bound to be the bundle classloader
of a JDT bundle which can load the required Eclipse compiler types.

NOTE: We cannot simply use the thread context class loader. This works in the Eclipse IDE
(where it is set to ContextFinder), but not in the JDT Language Server.
value-processor/src/org/immutables/processor/ProxyProcessor.java