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

Method getTemplateRange

output/java8/1.4.19/CompiledST.java:227–243  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

225
226
227 public Interval getTemplateRange() {
228 if ( isAnonSubtemplate ) {
229 int start = Integer.MAX_VALUE;
230 int stop = Integer.MIN_VALUE;
231 for (Interval interval : sourceMap) {
232 if ( interval==null ) {
233 continue;
234 }
235 start = Math.min(start, interval.a);
236 stop = Math.max(stop, interval.b);
237 }
238 if ( start<=stop+1 ) {
239 return new Interval(start, stop);
240 }
241 }
242 return new Interval(0, template.length()-1);
243 }
244
245
246 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