Javascript type conversion support
Add testcase for previous commit. Add missing assert for future type conversions support that will use the heap instead of pointer casts (for smart pointer type conversions). Closes #1963
This commit is contained in:
parent
fee5e239ec
commit
04b46cc8a3
4 changed files with 19 additions and 0 deletions
|
|
@ -291,6 +291,7 @@ SWIGRUNTIME int SWIG_V8_ConvertInstancePtr(SWIGV8_OBJECT objRef, void **ptr, swi
|
|||
}
|
||||
int newmemory = 0;
|
||||
*ptr = SWIG_TypeCast(tc, cdata->swigCObject, &newmemory);
|
||||
assert(!newmemory); /* newmemory handling not yet implemented */
|
||||
} else {
|
||||
*ptr = cdata->swigCObject;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -64,6 +64,7 @@
|
|||
#include <errno.h>
|
||||
#include <limits.h>
|
||||
#include <stdlib.h>
|
||||
#include <assert.h>
|
||||
%}
|
||||
|
||||
%insert(runtime) "swigrun.swg"; /* SWIG API */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue