Github user blackdrag commented on a diff in the pull request:

    https://github.com/apache/groovy/pull/219#discussion_r61761881
  
    --- Diff: src/main/org/codehaus/groovy/reflection/ClassInfo.java ---
    @@ -35,13 +36,13 @@
      *
      * @author Alex.Tkachman
      */
    -public class ClassInfo {
    +public class ClassInfo implements Finalizable {
     
         private final LazyCachedClassRef cachedClassRef;
         private final LazyClassLoaderRef artifactClassLoader;
         private final LockableObject lock = new LockableObject();
         public final int hash = -1;
    -    private final Class klazz;
    +    private final WeakReference<Class<?>> klazz;
    --- End diff --
    
    I wonder what we should do if the referenced class has been collected. At 
least in the non - ClassValue version, it might be, that the ClassInfo still 
exists. And if then somebody tries to get the meta class using that ClassInfo 
things will blow up


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

Reply via email to