Skip to content

Commit

Permalink
handling function arity
Browse files Browse the repository at this point in the history
  • Loading branch information
SuperFola committed Jul 25, 2019
1 parent 7a80f88 commit 8a1a3e8
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions include/Ark/VM/VM.inl
Original file line number Diff line number Diff line change
Expand Up @@ -790,11 +790,7 @@ inline void VM_t<debug>::mut()
if constexpr (debug)
Ark::logger.info("MUT ({0}) PP:{1}, IP:{2}"s, m_symbols[id], m_pp, m_ip);

// if stack is empty, MUT id has no effect
if (m_frames.back().stackSize() != 0)
registerVariable(id, pop());
else
registerVariable(id, FFI::nil);
registerVariable(id, pop());
}

template<bool debug>
Expand Down

0 comments on commit 8a1a3e8

Please sign in to comment.