On Windows 10, I downloaded and installed Eclipse Oxygen [Release (4.7.1a) Build id: 20171005-1200] using the Eclipse Installer .
Then I created a trivial Java project (without module material) using the Project Creation Wizard:
public class Demo1 { public static void main(String[] args) { new Demo1().test(0L); } void test(int i) { doStuff(); } void test(long l) { doStuff(); } void doStuff() { String s = "abcde"; s = s.substring(2,4); System.out.print("s="); System.out.println( s.toString()); } }
It works fine, and if I do CTL => Open Implementation for test () or doStuff () or System or String or toString () or substr () everything is fine.
However, for println () and print () , an error message is displayed:
! ENTRY org.eclipse.jdt.ui 4 0 2017-10-23 01: 42: 54.695! "print". .! STACK 1 Java Model: Java- [ ] org.eclipse.jdt.internal.core.JavaElement. newJavaModelException (JavaElement.java:570) org.eclipse.jdt.internal.core.Openable.generateInfos(Openable.java:247) org.eclipse.jdt.internal.core.Openable.openAncestors(Openable.java:505) org.eclipse.jdt.internal.core.Openable.generateInfos(Openable.java:241) org.eclipse.jdt.internal.core.Openable.openAncestors(Openable.java:505) org.eclipse.jdt.internal.core.Openable.generateInfos(Openable.java:241) org.eclipse.jdt.internal.core.SourceRefElement.generateInfos(SourceRefElement.java:107) org.eclipse.jdt.internal.core.JavaElement.openWhenClosed(JavaElement.java:583) org.eclipse.jdt.internal.core.BinaryType.getElementInfo(BinaryType.java:287) org.eclipse.jdt.internal.core.JavaElement.getElementInfo(JavaElement.java:306) org.eclipse.jdt.internal.core.BinaryType.isInterface(BinaryType.java:725) org.eclipse.jdt.internal.ui.javaeditor.JavaElementImplementationHyperlink $1.run(JavaElementImplementationHyperlink.java:237) org.eclipse.jface.operation.ModalContext $ModalContextThread.run(ModalContext.java:119) SUBENTRY 1 org.eclipse.jdt.core 4 1006 2017-10-23 01: 42: 54,695! MESSAGE
Eclipse , , . :
- ?
- , / , ?
, print() println()?
, , , @ZhekaKozlov @Stephan Photon M3 , : -
. Eclipse Java Runtime 9, Java 9. , Java 9 .
Java Runtime 9 , :
, --add-modules=ALL-SYSTEM , -vmargs arg eclipse.ini.
--add-modules=ALL-SYSTEM
-vmargs
eclipse.ini
Source: https://habr.com/ru/post/1687991/More articles:window.history.back illegal call - javascriptGetting "Internal error: Scala instance does not exist or is invalid" when trying to start a worksheet in IntelliJ IDEA - scalaiPhone X Aligning the bottom of an object in the ruins of Safe Area on other devices - iosWhy does GCC say that a variable is not used when it is not? - cThe audio file captured by MediaRecorder is damaged after it is sent to the server using Retrofit 2 - androidPlain Kotlin module in Android Studio 3.0, `api` is not supported? - androidError creating opencv with ffmpeg - c ++Create a new column based on the index column - rChange the default animation for a tablet with a different animation - nao-robotConvert strings from number to string in awk - unixAll Articles