Can some one help me to find out how to apply Type erasure/generics to make it work.
Set<? extends Object> ss = new HashSet<Integer>();
Set<? extends Object> sa = new HashSet<Integer>();
ss.addAll(sa);
Now it throwing compilation error, since it will check for type at compile time.