summaryrefslogtreecommitdiffstats
path: root/php-nikic-php-parser-autoload.php
blob: 61dca275dda8b0ed743ad230f7b7c170c7fd8b7a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
<?php
/**
 * Autoloader for nikic/php-parser and its dependencies
 */

$vendorDir = '/usr/share/php';

// Use Symfony PSR4 autoloader
if (!isset($fedoraPsr4ClassLoader) || !($fedoraPsr4ClassLoader instanceof \Symfony\Component\ClassLoader\Psr4ClassLoader)) {
    if (!class_exists('Symfony\\Component\\ClassLoader\\Psr4ClassLoader', false)) {
        require_once '/usr/share/php/Symfony/Component/ClassLoader/Psr4ClassLoader.php';
    }

    $fedoraPsr4ClassLoader = new \Symfony\Component\ClassLoader\Psr4ClassLoader();
    $fedoraPsr4ClassLoader->register(true);
}

$fedoraPsr4ClassLoader->addPrefix('PhpParser\\', __DIR__);