Last active
August 29, 2015 14:20
-
-
Save agentgt/7aa05288b560a6190091 to your computer and use it in GitHub Desktop.
IntelliJ line continuation breaks on functions that take lambda/anonymous
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class IntelliBadLineContinuationTest { | |
@Test | |
public void testBlah() throws Exception { | |
//ok not so bad | |
asList("a") | |
.get(0) | |
.toString(); | |
//ok | |
asList( | |
"a", | |
"b", | |
"c") | |
.get(0) | |
.toString(); | |
//ok | |
Executors | |
.newCachedThreadPool() | |
.submit(new Callable<Object>() { | |
@Override | |
public Object call() throws Exception { | |
return null; | |
} | |
}) | |
.get(); | |
//oh snap wtf is that get doing? | |
execute(new Callable<Object>() { | |
@Override | |
public Object call() throws Exception { | |
return execute(new Callable<Object>() { | |
return null; | |
}) | |
.get(); | |
} | |
}); | |
} | |
public static <T> Future<T> execute(Callable<T> c) { | |
return Executors.newCachedThreadPool().submit(c); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment