Mercurial Hosting > luan
comparison core/src/luan/impl/UnmExpr.java @ 578:60c549d43988
remove LuanState.exception()
author | Franklin Schmidt <fschmidt@gmail.com> |
---|---|
date | Tue, 14 Jul 2015 17:40:48 -0600 |
parents | 4723d22062ce |
children | 859c0dedc8b6 |
comparison
equal
deleted
inserted
replaced
577:d7a85fbe15f1 | 578:60c549d43988 |
---|---|
24 LuanFunction fn = luan.getHandlerFunction("__unm",(LuanTable)o); | 24 LuanFunction fn = luan.getHandlerFunction("__unm",(LuanTable)o); |
25 if( fn != null ) { | 25 if( fn != null ) { |
26 return Luan.first(fn.call(luan,new Object[]{o})); | 26 return Luan.first(fn.call(luan,new Object[]{o})); |
27 } | 27 } |
28 } | 28 } |
29 throw luan.exception("attempt to perform arithmetic on a "+Luan.type(o)+" value"); | 29 throw new LuanException(luan,"attempt to perform arithmetic on a "+Luan.type(o)+" value"); |
30 } finally { | 30 } finally { |
31 luan.pop(); | 31 luan.pop(); |
32 } | 32 } |
33 } | 33 } |
34 } | 34 } |