Groups
Sign in
Groups
java.lang.fans
Conversations
About
Send feedback
Help
java.lang.fans
Contact owners and managers
1–26 of 26
-- Pedantic Java Programmers Obsessed with Intricate and Useless Language Details
--
[ Join ]
Joining is not required for posting; simply email to
java-lang-fans@googlegroups.
com
--
Mark all as read
Report group
0 selected
srdjan mitrovic
,
Zhong Yu
5
8/11/16
Why is Collections.unmodifiableList not defined to return List<? extends T> instead of List<T> ?
Srdjan, If you have <? extends Integer> in your APIs, you are a highly disciplined purist:)
unread,
Why is Collections.unmodifiableList not defined to return List<? extends T> instead of List<T> ?
Srdjan, If you have <? extends Integer> in your APIs, you are a highly disciplined purist:)
8/11/16
zhong...@gmail.com
,
Paul Bellora
8
1/12/16
Curious cases of up-casting
[up-cast case] - a parent member is hidden by the child class class Parent { String x = "x"
unread,
Curious cases of up-casting
[up-cast case] - a parent member is hidden by the child class class Parent { String x = "x"
1/12/16
zhong...@gmail.com
2
11/11/15
The type of `0` (Implicit narrowing conversion)
On Wed, Nov 11, 2015 at 2:20 PM, <zhong...@gmail.com> wrote: [c1-6] only apply for `byte/
unread,
The type of `0` (Implicit narrowing conversion)
On Wed, Nov 11, 2015 at 2:20 PM, <zhong...@gmail.com> wrote: [c1-6] only apply for `byte/
11/11/15
Zhong Yu
11/5/15
null.toString()
http://stackoverflow.com/q/33548305/2158288
unread,
null.toString()
http://stackoverflow.com/q/33548305/2158288
11/5/15
zhong...@gmail.com
2
11/3/15
Method Reference vs Lambda Expression
Return statements in lambda body need to be consistent wrt to `void` void execute(Runnable command) {
unread,
Method Reference vs Lambda Expression
Return statements in lambda body need to be consistent wrt to `void` void execute(Runnable command) {
11/3/15
zhong...@gmail.com
,
y s
5
10/16/15
complex `?:` case
Another case - http://stackoverflow.com/q/33177256/2158288
unread,
complex `?:` case
Another case - http://stackoverflow.com/q/33177256/2158288
10/16/15
zhong...@gmail.com
10/13/15
recursion, self-referencing lambda, y-combinator
Say we want to define a function recursively, eg factorial fac(n) = n*fac(n-1) // n>0 fac(0) = 1
unread,
recursion, self-referencing lambda, y-combinator
Say we want to define a function recursively, eg factorial fac(n) = n*fac(n-1) // n>0 fac(0) = 1
10/13/15
Zhong Yu
,
y s
6
10/6/15
Undenotable types in Java
Yeah, that's a good point. I wouldn't be surprised if the compiler did internally have a name
unread,
Undenotable types in Java
Yeah, that's a good point. I wouldn't be surprised if the compiler did internally have a name
10/6/15
zhong...@gmail.com
9/25/15
Simulate `goto`
(an answer I wrote to an SO question, which is then deleted) `goto` is great in modeling a complex
unread,
Simulate `goto`
(an answer I wrote to an SO question, which is then deleted) `goto` is great in modeling a complex
9/25/15
zhong...@gmail.com
,
y s
5
9/21/15
"final" default method?
On Monday, September 21, 2015 at 2:07:44 PM UTC-5, Yuval Shavit wrote: "Every method declaration
unread,
"final" default method?
On Monday, September 21, 2015 at 2:07:44 PM UTC-5, Yuval Shavit wrote: "Every method declaration
9/21/15
zhong...@gmail.com
,
y s
3
9/18/15
Express intersection A&B in Java
On Friday, September 18, 2015 at 3:15:04 PM UTC-5, Yuval Shavit wrote: Wouldn't you be able to do
unread,
Express intersection A&B in Java
On Friday, September 18, 2015 at 3:15:04 PM UTC-5, Yuval Shavit wrote: Wouldn't you be able to do
9/18/15
zhong...@gmail.com
,
y s
5
9/17/15
Choice of wildcard in an API design case
Similar cases: Collections min/max() <T> T min(Collection<? extends T> coll, Comparator
unread,
Choice of wildcard in an API design case
Similar cases: Collections min/max() <T> T min(Collection<? extends T> coll, Comparator
9/17/15
zhong...@gmail.com
,
y s
7
9/9/15
constant variable that's not static
There are 10 kinds of variables: those that understand base 7, and those that don't... or
unread,
constant variable that's not static
There are 10 kinds of variables: those that understand base 7, and those that don't... or
9/9/15
zhong...@gmail.com
,
y s
4
9/8/15
Supply super constructor with lambda expression that captures `this`
On Monday, June 15, 2015 at 8:53:31 PM UTC-5, zhong...@gmail.com wrote: There is no way to supply a
unread,
Supply super constructor with lambda expression that captures `this`
On Monday, June 15, 2015 at 8:53:31 PM UTC-5, zhong...@gmail.com wrote: There is no way to supply a
9/8/15
zhong...@gmail.com
9/3/15
Capturing Wildcard (Java Generics Article)
This is an article I'm writing on the topic of Wildcard http://bayou.io/draft/Capturing_Wildcards
unread,
Capturing Wildcard (Java Generics Article)
This is an article I'm writing on the topic of Wildcard http://bayou.io/draft/Capturing_Wildcards
9/3/15
zhong...@gmail.com
8/31/15
Avoiding unwanted return value in a java lambda
http://stackoverflow.com/questions/32316262 Any good ideas? Zhong
unread,
Avoiding unwanted return value in a java lambda
http://stackoverflow.com/questions/32316262 Any good ideas? Zhong
8/31/15
y s
,
Zhong Yu
4
8/11/15
double wildcards
An up-cast is needed somewhere to access the parent private member. In this solution public static
unread,
double wildcards
An up-cast is needed somewhere to access the parent private member. In this solution public static
8/11/15
Zhong Yu
8/1/15
Well-formed-ness of paramterized types
http://stackoverflow.com/questions/31751836/java-covariant-wildcard-bounds-in-method-parameters
unread,
Well-formed-ness of paramterized types
http://stackoverflow.com/questions/31751836/java-covariant-wildcard-bounds-in-method-parameters
8/1/15
Zhong Yu
7/9/15
Type inference - RuntimeException is inferred from upper bound Throwable
http://stackoverflow.com/questions/31316581/a-peculiar-feature-of-exception-type-inference-in-java-8
unread,
Type inference - RuntimeException is inferred from upper bound Throwable
http://stackoverflow.com/questions/31316581/a-peculiar-feature-of-exception-type-inference-in-java-8
7/9/15
zhong...@gmail.com
7/5/15
Terminology - Type Parameter vs Type Variable
(Warning, too long, uninteresting, do not read :) In Java generics, we have terms "type
unread,
Terminology - Type Parameter vs Type Variable
(Warning, too long, uninteresting, do not read :) In Java generics, we have terms "type
7/5/15
Zhong Yu
6/18/15
Method return type erased because of raw-type arguments
(a different issue than erasing instance methods of a raw-type) http://stackoverflow.com/q/30918308/
unread,
Method return type erased because of raw-type arguments
(a different issue than erasing instance methods of a raw-type) http://stackoverflow.com/q/30918308/
6/18/15
Zhong Yu
6/16/15
"Overriding" static method
http://stackoverflow.com/a/30880161/2158288
unread,
"Overriding" static method
http://stackoverflow.com/a/30880161/2158288
6/16/15
Zhong Yu
6/12/15
Why does Java allow type arguments for non-generic methods
http://stackoverflow.com/questions/28014853/what-is-the-point-of-allowing-type-witnesses-on-all-
unread,
Why does Java allow type arguments for non-generic methods
http://stackoverflow.com/questions/28014853/what-is-the-point-of-allowing-type-witnesses-on-all-
6/12/15
Zhong Yu
2
6/2/15
[java.lang.fans] - Erasure and Backward Compatibility
The best I can find - http://gafter.blogspot.com/2006/11/reified-generics-for-java.html > Neal
unread,
[java.lang.fans] - Erasure and Backward Compatibility
The best I can find - http://gafter.blogspot.com/2006/11/reified-generics-for-java.html > Neal
6/2/15
Zhong Yu
5/22/15
Please forward interesting questions to java.lang.fans
If you see an interesting question somewhere else, eg stackoverflow, you can forward the link here,
unread,
Please forward interesting questions to java.lang.fans
If you see an interesting question somewhere else, eg stackoverflow, you can forward the link here,
5/22/15
Zhong Yu
3
5/22/15
Test
test test String x = ""; On Fri, May 22, 2015 at 12:36 PM, <zhong...@gmail.com>
unread,
Test
test test String x = ""; On Fri, May 22, 2015 at 12:36 PM, <zhong...@gmail.com>
5/22/15