< prev index next >

src/jdk.compiler/share/classes/com/sun/tools/javac/jvm/CRTable.java

Print this page




 265         public void visitBlock(JCBlock tree) {
 266             SourceRange sr = new SourceRange(startPos(tree), endPos(tree));
 267             csp(tree.stats);    // doesn't compare because block's ending position is defined
 268             result = sr;
 269         }
 270 
 271         public void visitDoLoop(JCDoWhileLoop tree) {
 272             SourceRange sr = new SourceRange(startPos(tree), endPos(tree));
 273             sr.mergeWith(csp(tree.body));
 274             sr.mergeWith(csp(tree.cond));
 275             result = sr;
 276         }
 277 
 278         public void visitWhileLoop(JCWhileLoop tree) {
 279             SourceRange sr = new SourceRange(startPos(tree), endPos(tree));
 280             sr.mergeWith(csp(tree.cond));
 281             sr.mergeWith(csp(tree.body));
 282             result = sr;
 283         }
 284 







 285         public void visitForLoop(JCForLoop tree) {
 286             SourceRange sr = new SourceRange(startPos(tree), endPos(tree));
 287             sr.mergeWith(csp(tree.init));
 288             sr.mergeWith(csp(tree.cond));
 289             sr.mergeWith(csp(tree.step));
 290             sr.mergeWith(csp(tree.body));
 291             result = sr;
 292         }
 293 
 294         public void visitForeachLoop(JCEnhancedForLoop tree) {
 295             SourceRange sr = new SourceRange(startPos(tree), endPos(tree));
 296             sr.mergeWith(csp(tree.var));
 297             sr.mergeWith(csp(tree.expr));
 298             sr.mergeWith(csp(tree.body));
 299             result = sr;
 300         }
 301 
 302         public void visitLabelled(JCLabeledStatement tree) {
 303             SourceRange sr = new SourceRange(startPos(tree), endPos(tree));
 304             sr.mergeWith(csp(tree.body));




 265         public void visitBlock(JCBlock tree) {
 266             SourceRange sr = new SourceRange(startPos(tree), endPos(tree));
 267             csp(tree.stats);    // doesn't compare because block's ending position is defined
 268             result = sr;
 269         }
 270 
 271         public void visitDoLoop(JCDoWhileLoop tree) {
 272             SourceRange sr = new SourceRange(startPos(tree), endPos(tree));
 273             sr.mergeWith(csp(tree.body));
 274             sr.mergeWith(csp(tree.cond));
 275             result = sr;
 276         }
 277 
 278         public void visitWhileLoop(JCWhileLoop tree) {
 279             SourceRange sr = new SourceRange(startPos(tree), endPos(tree));
 280             sr.mergeWith(csp(tree.cond));
 281             sr.mergeWith(csp(tree.body));
 282             result = sr;
 283         }
 284 
 285         public void visitWithField(JCWithField tree) {
 286             SourceRange sr = new SourceRange(startPos(tree), endPos(tree));
 287             sr.mergeWith(csp(tree.field));
 288             sr.mergeWith(csp(tree.value));
 289             result = sr;
 290         }
 291 
 292         public void visitForLoop(JCForLoop tree) {
 293             SourceRange sr = new SourceRange(startPos(tree), endPos(tree));
 294             sr.mergeWith(csp(tree.init));
 295             sr.mergeWith(csp(tree.cond));
 296             sr.mergeWith(csp(tree.step));
 297             sr.mergeWith(csp(tree.body));
 298             result = sr;
 299         }
 300 
 301         public void visitForeachLoop(JCEnhancedForLoop tree) {
 302             SourceRange sr = new SourceRange(startPos(tree), endPos(tree));
 303             sr.mergeWith(csp(tree.var));
 304             sr.mergeWith(csp(tree.expr));
 305             sr.mergeWith(csp(tree.body));
 306             result = sr;
 307         }
 308 
 309         public void visitLabelled(JCLabeledStatement tree) {
 310             SourceRange sr = new SourceRange(startPos(tree), endPos(tree));
 311             sr.mergeWith(csp(tree.body));


< prev index next >