MCPcopy Index your code
hub / github.com/antlr/codebuff / getTemplateRange

Method getTemplateRange

output/java8/1.4.12/CompiledST.java:223–239  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

221
222
223 public Interval getTemplateRange() {
224 if ( isAnonSubtemplate ) {
225 int start = Integer.MAX_VALUE;
226 int stop = Integer.MIN_VALUE;
227 for (Interval interval : sourceMap) {
228 if ( interval==null ) {
229 continue;
230 }
231 start = Math.min(start, interval.a);
232 stop = Math.max(stop, interval.b);
233 }
234 if ( start<= stop+1 ) {
235 return new Interval(start, stop);
236 }
237 }
238 return new Interval(0, template.length()-1);
239 }
240
241
242 public String instrs() {

Callers 2

getTemplateSourceMethod · 0.95
updateCurrentSTMethod · 0.45

Calls 3

minMethod · 0.45
maxMethod · 0.45
lengthMethod · 0.45

Tested by

no test coverage detected