So, I'm a little confused about changing Java 8 - List.sort - bear with me, as the confusion will become apparent.
I have a Java 8 JDK installed and running Eclipse with a given project to compile in version 1.6 (Windows environment).
Throughout my code that I have been doing (the example extends BaseExample):
public static final Comparator<BaseExample> sortByLevel_DESC = new Comparator<NavItemBase>() {...}; List<Example> examples = new ArrayList<Example>(); examples.sort(sortByLevel_DESC);
Despite compiling to 1.6, it worked and always worked for me (remember that I have Java 8 installed).
But...
From the moment this code is applied to the client machine - with Java 7 (JRE not JDK) installed (Linux environment), the exception "java.util.List.sort () NoSuchMethodException" is thrown.
Changing the code from: examples.sort(sortByLevel_DESC); before: Collections.sort(examples, sortByLevel_DESC); fixes the problem.
This leads me to the obvious conclusion that it crashes because of the specific code of Java 8 and because Java 8 is not installed.
But I'm not interested ...
Why does eclipse not complain about Java 8 code when it is not compiled in Java 8 in the same way as it will complain if you try to use lambda expressions rather than compiled in Java 8:
examples.stream().filter(e -> e.active()).collect(Collectors.toList());
(e -> e.active ()) is the problem:

I would think if the method was only java 8, and I was compiled to 6, then only java 6 code can be executed - I really relied on this “specific project” to ensure that I don’t write any code that is incompatible with the lower version that clients often have, for example, when I tried the lambda expression.
Perhaps this is a problem with Eclipse and not with Java? Or perhaps this is NOT the same as lambda expressions in general (in how it should show an error)?