Skip to content

Commit

Permalink
Minor refactoring
Browse files Browse the repository at this point in the history
  • Loading branch information
bamless committed May 1, 2024
1 parent 518d0c4 commit 1ba9276
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/jstar.c
Expand Up @@ -310,7 +310,9 @@ void jsrRaiseException(JStarVM* vm, int slot) {
void jsrRaise(JStarVM* vm, const char* cls, const char* err, ...) {
PROFILE_FUNC()

if(!jsrGetGlobal(vm, NULL, cls)) return;
if(!jsrGetGlobal(vm, NULL, cls)) {
return;
}

ObjInstance* exception = newInstance(vm, AS_CLASS(pop(vm)));
if(!isInstance(vm, OBJ_VAL(exception), vm->excClass)) {
Expand Down

0 comments on commit 1ba9276

Please sign in to comment.