diff options
author | Bill Welden <bwelden@imvu.com> | 2012-12-05 12:27:06 -0800 |
---|---|---|
committer | Jukka Jylänki <jujjyl@gmail.com> | 2013-04-12 14:22:23 +0300 |
commit | 119ab2f1c412c7eb4863f852a690cdf215339b07 (patch) | |
tree | cdb0c12b5b0a9bc64583981535050b5fcbba3153 /src | |
parent | 51cdfb5fdb74871c2d0ebb23635f5d28dfdacb43 (diff) |
Better error reporting
Fixed demangling routine and added it to RTL
New __typeName method to retrieve char* type name from type info
Diffstat (limited to 'src')
-rwxr-xr-x | src/embind/embind.js | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/embind/embind.js b/src/embind/embind.js index 2c5d20c0..e990c1a1 100755 --- a/src/embind/embind.js +++ b/src/embind/embind.js @@ -137,15 +137,15 @@ var BindingError = Error; /** @expose */ Module.BindingError = BindingError; -function typeName(typeID) { - // could use our carnal knowledge of RTTI but for now just return the pointer... - return typeID; +/*global ___typeName:false*/ +function typeName(type) { + return Pointer_stringify(___typeName(type)); } function requireRegisteredType(type, humanName) { var impl = typeRegistry[type]; if (undefined === impl) { - throw new BindingError(humanName + " has unknown type: " + typeName(type)); + throw new BindingError(humanName + " has unknown type " + typeName(type)); } return impl; } |