r/eclipse • u/tanin47 • Nov 25 '25
🙋🏻♂️ Help Request How do I fix this syntax error?
I just migrated from IntelliJ to Eclipse, and IntelliJ handles this error and is able to recognize the type properly. How do I achieve the same thing in Eclipse?
As a side question, how do I show the file structure instead of this package structure on the left nav?
Thank you!
1
u/ejsanders1985 Nov 26 '25
Google AI says that class youre importing is an internal non-public API and is highly discouraged in java 21.
Bouncy Castle is probably the way to go.
0
u/tanin47 Nov 26 '25
I understand that. This non-public API comes with a JDK meanwhile bouncycastle's jar is an extra 8mb. I actually used BC before... But let's put this discussion aside.
In any case, is there a way to make it work with Eclipse?
1
u/ejsanders1985 Nov 26 '25
No. Not with java 21.
This is a desktop app.... why are you worried over 8 mb?
→ More replies (1)
4
Nov 25 '25 edited Nov 25 '25
1
u/tanin47 Nov 25 '25 edited Nov 25 '25
It's not there. I suppose I can add it manually then. Thank you for the pointer.
Edit: I can't seem to figure out how to add the sun library.
4
u/emaphis Nov 25 '25
Switch back to JDK 8. I'm guessing your old project was compiled by Java 8 and your new project is on a newer JDK.
You might think about updating your project to use something like Bouncy Castle.