Avoid stringly approach.

This commit is contained in:
Juraj Kirchheim
2016-06-10 08:20:09 +02:00
parent 4207dea754
commit 983ffa16af

View File

@@ -168,12 +168,11 @@ class Types {
sub : null,
});
static function resolveDirectType()
return
switch reduce(Context.getLocalType()) {
case TInst(_, [TInst(_.get() => { kind: KExpr(e) }, _)]):
types.get(Std.parseInt(e.toString()))();
types[e.getInt().sure()]();
default:
throw 'assert';
}