-
Bug
-
Resolution: Fixed
-
P4
-
8, 11, 14, 16
-
b14
-
x86_64
-
windows_10
-
Verified
A DESCRIPTION OF THE PROBLEM :
The documentation for `java.lang.Class.getSimpleName()` says:
> Returns the simple name of the underlying class as given in the source code.
Lambdas and method references do not exist as class in the source code, so they have no name. Yet for both `getSimpleName()` returns a non-empty string.
---------- BEGIN SOURCE ----------
Runnable r = () -> {}
assert r.getClass().getSimpleName().isEmpty();
Runnable r2 = r::run;
assert r2.getClass().getSimpleName().isEmpty();
---------- END SOURCE ----------
The documentation for `java.lang.Class.getSimpleName()` says:
> Returns the simple name of the underlying class as given in the source code.
Lambdas and method references do not exist as class in the source code, so they have no name. Yet for both `getSimpleName()` returns a non-empty string.
---------- BEGIN SOURCE ----------
Runnable r = () -> {}
assert r.getClass().getSimpleName().isEmpty();
Runnable r2 = r::run;
assert r2.getClass().getSimpleName().isEmpty();
---------- END SOURCE ----------