1 package polyglot.ext.jl.ast; 2 3 import polyglot.ast.*; 4 import polyglot.types.*; 5 import polyglot.visit.*; 6 import polyglot.util.*; 7 8 11 public class NullLit_c extends Lit_c implements NullLit 12 { 13 public NullLit_c(Position pos) { 14 super(pos); 15 } 16 17 18 public Node typeCheck(TypeChecker tc) { 19 return type(tc.typeSystem().Null()); 20 } 21 22 23 public Object objValue() { 24 return null; 25 } 26 27 public String toString() { 28 return "null"; 29 } 30 31 32 public void prettyPrint(CodeWriter w, PrettyPrinter tr) { 33 w.write("null"); 34 } 35 36 public Object constantValue() { 37 return null; 38 } 39 } 40 | Popular Tags |