Commit 9fb2fa6b authored by Julian Kranz's avatar Julian Kranz

dgdsl

parent 6b80b1a6
......@@ -34,7 +34,6 @@ class Extension : Expression {
}
public override string toString() {
//return "[" ~ to!string(fromSize) ~ "->" ~ cast(string)_op ~ "]" ~ _opnd.toString();
return "[" ~ to!string(_fromSize) ~ "->" ~ cast(string)_op ~ "]" ~ _opnd.toString();
}
}
......
module gdsl.rreil.expr.sexpr;
import gdsl.rreil.expr.expr;
import sexpr = gdsl.rreil.sexpr.sexpr;
class Sexpr : Expression {
private sexpr.Sexpr _inner;
@property public sexpr.Sexpr inner() {
return _inner;
}
public this(sexpr.Sexpr inner) {
_inner = inner;
}
public override string toString() {
return _inner.toString();
}
}
unittest {
import gdsl.rreil.sexpr.arbitrary;
Sexpr s = new Sexpr(new Arbitrary());
assert(s.toString == "arbitrary");
}
\ No newline at end of file
module gdsl.rreil.sexpr.arbitrary;
import gdsl.rreil.sexpr.sexpr;
class Arbitrary : Sexpr {
public override string toString() {
return "arbitrary";
}
}
unittest {
Arbitrary a = new Arbitrary();
assert(a.toString == "arbitrary");
}
\ No newline at end of file
module gdsl.rreil.sexpr.linear;
import gdsl.rreil.sexpr.sexpr;
import linear = gdsl.rreil.linear.linear;
class Linear : Sexpr {
private linear.Linear _inner;
@property public linear.Linear inner() {
return _inner;
}
public this(linear.Linear inner) {
this._inner = inner;
}
public override string toString() {
return _inner.toString();
}
}
unittest {
import gdsl.rreil.linear.immediate;
Linear l = new Linear(new Immediate(99));
assert(l.toString() == "99");
}
\ No newline at end of file
module gdsl.rreil.sexpr.sexpr;
class Sexpr {
public abstract override string toString();
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment