1 // Copyright (c) 2004 Per M.A. Bothner. 2 // This is free software; for terms and warranty disclaimer see ./COPYING. 3 4 package gnu.expr; 5 import gnu.kawa.io.OutPort; 6 import gnu.mapping.*; 7 8 /** A language-specific expression. */ 9 10 public class LangExp extends Expression 11 { 12 Object hook; 13 getLangValue()14 public Object getLangValue () { return hook; } setLangValue(Object value)15 public void setLangValue (Object value) { hook = value; } 16 LangExp()17 public LangExp () { } 18 LangExp(Object value)19 public LangExp (Object value) { this.hook = value; } 20 mustCompile()21 protected boolean mustCompile () { return false; } 22 print(OutPort out)23 public void print (OutPort out) 24 { 25 out.print("(LangExp ???)"); 26 } 27 visit(ExpVisitor<R,D> visitor, D d)28 protected <R,D> R visit (ExpVisitor<R,D> visitor, D d) 29 { 30 return visitor.visitLangExp(this, d); 31 } 32 compile(Compilation comp, Target target)33 public void compile (Compilation comp, Target target) 34 { 35 throw new RuntimeException("compile called on LangExp"); 36 } 37 } 38