There are a number of ops that could fail. Examples are find_lex but also the various load and lookup ops. Options for handling failure are:
I would therefore vote for a feature where I (as language designer) could indicate whether for instance a find_lex (but others too) fails silently (null return value) or with an exception.
Or you install an exception handler that just returns, when a LEXICAL_NOT_FOUND exception object is seen.
But this is only possible at opcode level. Anyway, we first should move the internal_exception out of scratchpad_get (and similar) to the opcode. Then we can do both, throw a resumable exception or ignore the error (depending on your poposed flags). We already have ctx->warns for e.g. PerlUndef warnings, why not an error flag too.
++Jos.es
leo