Merge pull request #1859 from adelva1984/no-host-exceptions

javascript: replace exceptions with SWIG_exit
This commit is contained in:
William S Fulton 2020-10-07 22:09:01 +01:00 committed by GitHub
commit 8889635683
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1575,7 +1575,8 @@ void JSCEmitter::marshalInputArgs(Node *n, ParmList *parms, Wrapper *wrapper, Ma
Printf(arg, "argv[%d]", i);
break;
default:
throw "Illegal state.";
Printf(stderr, "Illegal MarshallingMode.");
SWIG_exit(EXIT_FAILURE);
}
tm = emitInputTypemap(n, p, wrapper, arg);
Delete(arg);
@ -2212,7 +2213,8 @@ void V8Emitter::marshalInputArgs(Node *n, ParmList *parms, Wrapper *wrapper, Mar
Printf(arg, "args[%d]", i);
break;
default:
throw "Illegal state.";
Printf(stderr, "Illegal MarshallingMode.");
SWIG_exit(EXIT_FAILURE);
}
tm = emitInputTypemap(n, p, wrapper, arg);