Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ecore,uml] Fix Java 10 failure on CharBuffer.flip #1979

Closed
eclipse-ocl-bot opened this issue Sep 25, 2024 · 2 comments
Closed

[ecore,uml] Fix Java 10 failure on CharBuffer.flip #1979

eclipse-ocl-bot opened this issue Sep 25, 2024 · 2 comments

Comments

@eclipse-ocl-bot
Copy link
Collaborator

| --- | --- |
| Bugzilla Link | 534950 |
| Status | RESOLVED FIXED |
| Importance | P3 normal |
| Reported | May 22, 2018 10:40 EDT |
| Modified | May 22, 2018 19:04 EDT |
| Reporter | Ed Willink |

Description

After upgrading to Java 10 for Photon RC1, everything seems gto work except the Classic OCL DocumentParsingTests that fail at:

java.lang.NoSuchMethodError: java.nio.CharBuffer.flip()Ljava/nio/CharBuffer;
at org.eclipse.ocl.OCLInput.buildStringFromReader(OCLInput.java:128)
at org.eclipse.ocl.OCLInput.getContentAsString(OCLInput.java:110)
at org.eclipse.ocl.OCL.parse(OCL.java:288)
at org.eclipse.ocl.uml.tests.OCLDocumentTest.setUp(OCLDocumentTest.java:231)

which seems impossible, but one method we can workaround easily.

@eclipse-ocl-bot
Copy link
Collaborator Author

By Ed Willink on May 22, 2018 10:49

(In reply to Ed Willink from comment #0)

everything seems to work except the Classic OCL DocumentParsingTests

The Generate OCL Pivot Model transformation fails at this too, so it looks like QVTo and presumably anything that loads Classic OCL is broken.

@eclipse-ocl-bot
Copy link
Collaborator Author

By Ed Willink on May 22, 2018 19:04

plasma-umass/doppio#497 provides the fix.

Just cast the CharBuffer to Buffer before invoking flip() to avoid a JDK 8/9 signature chnage sensitivity.

Pushed to master for RC2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant