logo       
Google Custom Search
    AddThis Social Bookmark Button

Nice/src/nice/tools/typing Types.java,1.8,1.9: msg#00033

Subject: Nice/src/nice/tools/typing Types.java,1.8,1.9
Update of /cvsroot/nice/Nice/src/nice/tools/typing
In directory 
sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23666/F:/nice/src/nice/tools/typing

Modified Files:
        Types.java 
Log Message:
Java methods/fields with parametric types get type parameters with UnknownType 
instead of being ignored.

Index: Types.java
===================================================================
RCS file: /cvsroot/nice/Nice/src/nice/tools/typing/Types.java,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -d -r1.8 -r1.9
*** Types.java  30 Jul 2004 19:08:43 -0000      1.8
--- Types.java  22 Nov 2004 23:21:05 -0000      1.9
***************
*** 189,192 ****
--- 189,205 ----
    }
  
+   public static Monotype unknownArgsMonotype(TypeConstructor tc)
+     throws BadSizeEx
+   {
+     if (tc.variance == null || tc.arity() == 0)
+       return new MonotypeConstructor(tc, null);
+ 
+     mlsub.typing.Monotype[] args = new mlsub.typing.Monotype[tc.arity()];
+     for (int i = 0; i < tc.arity(); i++)
+       args[i] = UnknownMonotype.instance;
+ 
+     return new MonotypeConstructor(tc, args);
+   }
+ 
    /****************************************************************
     * Type parameters



-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now. 
http://productguide.itmanagersjournal.com/



Try Searching:
servers, voip, java, networking, microsoft ...
<Prev in Thread] Current Thread [Next in Thread>