• 3rdp/build/js-execute-scr

    From Deuc¿@VERT to Git commit to main/sbbs/m on Fri Nov 20 15:38:00 2026
    https://gitlab.synchro.net/main/sbbs/-/commit/92e457aa3fc801296a4edb8e
    Added Files:
    3rdp/build/js-execute-script-in-scope.patch src/sbbs3/tests/scoped_execution/declarations.sjs nested.sjs run.js throws.sjs
    Modified Files:
    3rdp/build/GNUmakefile src/sbbs3/exec.cpp js_global.cpp js_internal.cpp mailsrvr.cpp
    Log Message:
    Preserve scoped script execution with VAROBJFIX enabled

    Add JS_ExecuteScriptInScope to select the supplied scope as the declaration object without changing context options. Keep ordinary script execution on
    the existing VAROBJFIX path, including during callbacks and nested execution. Use the scoped entry point for load/require, js.exec, scoped exit handlers,
    and the BBS and mail processor script scopes.

    Add a standalone regression covering declaration isolation, nested require, exit handlers, exceptions, and deferred callbacks after garbage collection. Validated with jsdoor and jsexec with VAROBJFIX enabled, plus 49 existing jsexec checks each with default options and VAROBJFIX enabled. Engine probes also pass with the interpreter and MethodJIT.

    Closes #1372.