spmallette commented on code in PR #3162:
URL: https://github.com/apache/tinkerpop/pull/3162#discussion_r2220548643
##########
gremlin-console/src/main/groovy/org/apache/tinkerpop/gremlin/console/GremlinGroovysh.groovy:
##########
@@ -107,41 +109,10 @@ class GremlinGroovysh extends Groovysh {
String importsSpec = this.getImportStatements()
// determine if this script is complete or not - if not it's a
multiline script
- def status = parser.parse([importsSpec] + current)
+ def status = remoteParser.parse([importsSpec] + current)
switch (status.code) {
case ParseCode.COMPLETE:
- if
(!Boolean.valueOf(getPreference(INTERPRETER_MODE_PREFERENCE_KEY, 'false')) ||
isTypeOrMethodDeclaration(current)) {
- // Evaluate the current buffer w/imports and dummy
statement
- List buff = [importsSpec] + [ 'true' ] + current
- try {
- interp.evaluate(buff)
- } catch(MultipleCompilationErrorsException t) {
- if (isIncompleteCaseOfAntlr4(t)) {
- // treat like INCOMPLETE case
- buffers.updateSelected(current)
- break
- }
- throw t
- } catch (MissingPropertyException mpe) {
Review Comment:
you can't have a `MissingPropertyException` anymore because this change
stops doing a local evaluation of the code in the interpreter. now it just
parses for correctness in the script itself.
--
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]