uschindler commented on code in PR #16549:
URL: https://github.com/apache/lucene/pull/16549#discussion_r3845352046
##########
lucene/expressions/src/test/org/apache/lucene/expressions/js/TestJavascriptCompiler.java:
##########
@@ -316,8 +317,36 @@ public void testRecursionDepth3a() throws Exception {
/** returns the error offset for further checks */
private int assertRecursionLimit(String src) {
- ParseException expected = expectThrows(ParseException.class, () ->
compile(src));
+ ParseException expected = expectThrows(ParseException.class, () ->
compileWithLargeStack(src));
assertTrue(expected.getMessage(), expected.getMessage().contains("Nesting
level too deep"));
return expected.getErrorOffset();
}
+
+ /**
+ * Compiles on a thread with a larger stack and rethrows whatever the
compiler threw. The
+ * nesting-depth listener needs {@link
JavascriptCompiler.DEFAULT_MAX_NESTING_DEPTH} levels of
Review Comment:
This must be a hash instead of dot for the reference.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]