Mercurial Hosting > luan
comparison core/src/luan/LuanPropertyMeta.java @ 428:df95199ca4c0
rename __newindex to __new_index
author | Franklin Schmidt <fschmidt@gmail.com> |
---|---|
date | Sat, 02 May 2015 20:10:31 -0600 |
parents | dae264ad6a7b |
children | d9df6d6cb927 |
comparison
equal
deleted
inserted
replaced
427:dae264ad6a7b | 428:df95199ca4c0 |
---|---|
50 | 50 |
51 @Override public boolean canNewindex() { | 51 @Override public boolean canNewindex() { |
52 return true; | 52 return true; |
53 } | 53 } |
54 | 54 |
55 @Override public void __newindex(LuanState luan,LuanTable tbl,Object key,Object value) throws LuanException { | 55 @Override public void __new_index(LuanState luan,LuanTable tbl,Object key,Object value) throws LuanException { |
56 Object obj = setters(tbl).rawGet(key); | 56 Object obj = setters(tbl).rawGet(key); |
57 if( obj == null ) | 57 if( obj == null ) |
58 throw luan.exception("can't set property '"+key+"'"); | 58 throw luan.exception("can't set property '"+key+"'"); |
59 if( !(obj instanceof LuanFunction) ) | 59 if( !(obj instanceof LuanFunction) ) |
60 throw luan.exception("set for '"+key+"' isn't a function"); | 60 throw luan.exception("set for '"+key+"' isn't a function"); |