feat: honor passed set in toReadableLines
This commit is contained in:
parent
ba0b4e06ad
commit
3d5be60fc7
@ -316,6 +316,7 @@ public class ObjectValue extends Value {
|
|||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
@Override public List<String> toReadableLines(Environment env, HashSet<ObjectValue> passed) {
|
@Override public List<String> toReadableLines(Environment env, HashSet<ObjectValue> passed) {
|
||||||
|
if (passed.contains(this)) return Arrays.asList("[circular]");
|
||||||
return toReadableLines(env, passed, new HashSet<>());
|
return toReadableLines(env, passed, new HashSet<>());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user