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

Add support for GraalJS script engine on RegExp checks #97

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

sdoeringNew
Copy link
Contributor

The addition of GraalJS has another advantage.

With ECMAScript 2018 more RegExp features have been added. Nashorn and Rhino do not support these changes but GraalJS does.

  • Named Capture Groups
  • Unicode Property Escapes
  • Lookbehind Assertions
  • (dotAll) Flag

I haven't add unit tests. The GraalJS dependency is 20MB big and recommends JDK 11. So I just tested it locally.

Copy link
Contributor Author

@sdoeringNew sdoeringNew left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't want to seem impatient, but could we get a release with this? 👼

@@ -71,7 +71,7 @@ private static boolean rhinoScript(final Method method, final Object... args)
{
return ImmutableList.of(
new Object[] { "[^]", true },
new Object[] { "(?<=foo)bar", false },
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had to change this.

With GraalJS this "Positive Lookbehind" is supported and wouldn't have failed as expected.

@sdoeringNew
Copy link
Contributor Author

Any update on this?

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

Successfully merging this pull request may close these issues.

1 participant