diff options
Diffstat (limited to 'apps/files_external/3rdparty/aws-sdk-php/Symfony/Component/ClassLoader/ClassMapGenerator.php')
-rw-r--r-- | apps/files_external/3rdparty/aws-sdk-php/Symfony/Component/ClassLoader/ClassMapGenerator.php | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/apps/files_external/3rdparty/aws-sdk-php/Symfony/Component/ClassLoader/ClassMapGenerator.php b/apps/files_external/3rdparty/aws-sdk-php/Symfony/Component/ClassLoader/ClassMapGenerator.php index 3b09305954f..7f83dbc5592 100644 --- a/apps/files_external/3rdparty/aws-sdk-php/Symfony/Component/ClassLoader/ClassMapGenerator.php +++ b/apps/files_external/3rdparty/aws-sdk-php/Symfony/Component/ClassLoader/ClassMapGenerator.php @@ -11,6 +11,10 @@ namespace Symfony\Component\ClassLoader; +if (!defined('T_TRAIT')) { + define('T_TRAIT', 0); +} + /** * ClassMapGenerator * @@ -39,7 +43,7 @@ class ClassMapGenerator /** * Iterate over all files in the given directory searching for classes * - * @param Iterator|string $dir The directory to search in or an iterator + * @param \Iterator|string $dir The directory to search in or an iterator * * @return array A class map array */ @@ -84,7 +88,6 @@ class ClassMapGenerator { $contents = file_get_contents($path); $tokens = token_get_all($contents); - $T_TRAIT = version_compare(PHP_VERSION, '5.4', '<') ? -1 : T_TRAIT; $classes = array(); @@ -111,7 +114,7 @@ class ClassMapGenerator break; case T_CLASS: case T_INTERFACE: - case $T_TRAIT: + case T_TRAIT: // Find the classname while (($t = $tokens[++$i]) && is_array($t)) { if (T_STRING === $t[0]) { |