void () { @Language("JAVA") String classText = """ import java.util.Collections; import java.util.List; /** * @noinspection ALL */ class SomeClass { static <T extends Number> void test(List<T> list) { T t = list.isEmpty() ? null : list . get ( 0); System.out.println(list.size() + ":" + t); } public static void main(String[] args) { List<String> origList = Collections.singletonList("foo"); List<Integer> casted = (List<Integer>) (List<?>) origList; test(casted); } } """; List<Trinity<String, Integer, Integer>> traceAndPositions = Arrays.asList( Trinity.create("Exception in thread \"main\" java.lang.ClassCastException: class java.lang.String cannot be cast to class java.lang.Number" + " (java.lang.String and java.lang.Number are in module java.base of loader 'bootstrap')\n", null, null), Trinity.create("\tat SomeClass.test(SomeClass.java:12)\n", 12, 25), Trinity.create("\tat SomeClass.main(SomeClass.java:20)\n", 20, 9)); checkColumnFinder(classText, traceAndPositions); }