You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
calibrate.sh SYNC drifts: analyzer builtin list, function_exists inline names, prelude files missing from the analyzer #646
tools/audit/calibrate.sh (the audit's honesty check) fails its SYNC section on main (dbb6fdd) and on shared-generics. Three independent drifts:
Analyze\Builtins misses ~55–60 names emitBuiltin dispatches — e.g. array_key_exists, in_array, stripos, range, strrev, json_validate, substr_count, class_alias, plus internal __mc_* / __mir_* helpers. A user program calling one of the public ones reads as an undefined function to the analyzer.
function_exists cannot see 8 inline builtins: array_key_exists, in_array, array_is_list, range, strrev, json_validate, substr_count, class_alias. A polyfill guard (if (!function_exists('x')) { function x() … }) around one would redefine a working function.
analyze_prelude_sources() omits 19 prelude files: intl*.php (16), pdo_mysql_off.php, pdo_pgsql_off.php, pdo_sqlite_off.php. Every function they declare reads as undefined to the analyzer.
Expected
bash tools/audit/calibrate.sh passes SYNC: the analyzer's builtin list and function_exists's view cover every user-visible dispatch name, and the analyzer indexes every prelude file.
Notes
Internal helper names (__mc_*, __mir_*, runtime, manticore, target) in item 1 are probably scraper noise, not real gaps; the check should skip them as item 2 already does.
Item 2 is the user-visible one: function_exists('in_array') answering false breaks the polyfill idiom.
Checked item 2 at run time: function_exists() answers true for all eight (array_key_exists, in_array, array_is_list, range, strrev, json_validate, substr_count, class_alias), same as php. The names resolve through their stdlib bodies, so this part of the check is stale rather than a user-visible bug. Items 1 and 3 are about the analyzer's view and still stand.
Activity
blacktrs commentedon Nov 11, 2026
Checked item 2 at run time:
function_exists()answers true for all eight (array_key_exists, in_array, array_is_list, range, strrev, json_validate, substr_count, class_alias), same as php. The names resolve through their stdlib bodies, so this part of the check is stale rather than a user-visible bug. Items 1 and 3 are about the analyzer's view and still stand.