Skip to content

Commit 7ae0112

Browse files
eregonandrykonchin
authored andcommitted
Clarify
1 parent 9e2104b commit 7ae0112

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/main/java/org/truffleruby/parser/TranslatorEnvironment.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -388,13 +388,13 @@ public TranslatorEnvironment getSurroundingMethodEnvironment() {
388388
return methodParent;
389389
}
390390

391-
/** Return either outer method/module/top level environment or in case of eval("...") the topmost environment of the
392-
* parsed (by eval) code */
391+
/** Return either outer method/module/top level environment or in case of eval("...") the outermost environment of
392+
* the parsed (by eval) code */
393393
public TranslatorEnvironment getSurroundingMethodOrEvalEnvironment() {
394394
TranslatorEnvironment environment = this;
395395

396396
// eval's parsing environment still has frameDescriptor not initialized,
397-
// but all the outer scopes are related to already parsed code and have initialized frameDescriptor.
397+
// but all the outer scopes are related to already parsed code and have frameDescriptor != null.
398398
while (environment.isBlock() && environment.getParent().frameDescriptor == null) {
399399
environment = environment.getParent();
400400
}

0 commit comments

Comments
 (0)