bug-classpath
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug classpath/42808] EnumSet.allOf behavior differs from Sun 1.5 with e


From: btaitelb at gmail dot com
Subject: [Bug classpath/42808] EnumSet.allOf behavior differs from Sun 1.5 with empty collection
Date: 19 Jan 2010 20:34:01 -0000


------- Comment #1 from btaitelb at gmail dot com  2010-01-19 20:34 -------
Created an attachment (id=19660)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=19660&action=view)
adds support for calling allOf on empty collections

This is my first go at a patch. I've tested this with empty collections, but
haven't tested with non-empty ones.

Is there a testsuite somewhere that includes tests for this class?

I pulled out the anonymous inner class implementation of an EnumSet from the
of(T first) method into a private static inner class, and moved the logic of
setting the enumClass and instantiating the store with the correct size to the
add(T val) method of the implementation class (where this logic takes place the
first time this method is called).


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42808





reply via email to

[Prev in Thread] Current Thread [Next in Thread]