2026-06-23 19:28:45 +03:00
|
|
|
<?php
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* PHPStan bootstrap for XC_VM.
|
|
|
|
|
*
|
2026-08-07 20:51:02 +03:00
|
|
|
* The project uses Composer PSR-4, but this bootstrap deliberately does NOT wire
|
|
|
|
|
* a project autoloader. PHPStan discovers every class/interface/function itself
|
|
|
|
|
* by statically scanning the directories listed under `paths` and
|
2026-08-09 19:36:41 +03:00
|
|
|
* `scanDirectories` in build/phpstan.dist.neon — no project code is executed. (The
|
2026-08-07 20:51:02 +03:00
|
|
|
* Composer-installed phpstan binary loads src/vendor/autoload.php for its own
|
|
|
|
|
* dependencies.)
|
2026-06-23 19:28:45 +03:00
|
|
|
*
|
|
|
|
|
* This file only defines the global constants the codebase references so that
|
|
|
|
|
* analysis of constant-dependent expressions stays accurate.
|
|
|
|
|
*
|
|
|
|
|
* @package XC_VM
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
$srcRoot = dirname(__DIR__, 2) . '/src';
|
|
|
|
|
|
|
|
|
|
if (!defined('MAIN_HOME')) {
|
|
|
|
|
define('MAIN_HOME', $srcRoot . '/');
|
|
|
|
|
}
|
|
|
|
|
|
2026-06-23 20:02:46 +03:00
|
|
|
// NOTE: constants.stub.php is loaded via its own bootstrapFiles entry in
|
2026-08-09 19:36:41 +03:00
|
|
|
// build/phpstan.dist.neon (so PHPStan tracks it for result-cache invalidation).
|