public void setTrimParseTree(boolean trimParseTrees) {
		if (trimParseTrees) {
			if (getTrimParseTree()) return;
			addParseListener(TrimToSizeListener.INSTANCE);
		}
		else {
			removeParseListener(TrimToSizeListener.INSTANCE);
		}
	}
Trim the internal lists of the parse tree during parsing to conserve memory.
This property is set to {@code false} by default for a newly constructed parser.

@param trimParseTrees {@code true} to trim the capacity of the {@link ParserRuleContext#children}
list to its size after a rule is parsed.
runtime/Java/src/org/antlr/v4/runtime/Parser.java