diff options
Diffstat (limited to 'php-zetacomponents-base-pr8.patch')
-rw-r--r-- | php-zetacomponents-base-pr8.patch | 62 |
1 files changed, 62 insertions, 0 deletions
diff --git a/php-zetacomponents-base-pr8.patch b/php-zetacomponents-base-pr8.patch new file mode 100644 index 0000000..d0c8d1c --- /dev/null +++ b/php-zetacomponents-base-pr8.patch @@ -0,0 +1,62 @@ +From 850e8287b035fa8b13bd5ab563eacaf1ee2ec1b5 Mon Sep 17 00:00:00 2001 +From: Remi Collet <remi@remirepo.net> +Date: Mon, 30 Oct 2017 12:27:03 +0100 +Subject: [PATCH] object is a reserved keywork in PHP 7.2 + +--- + tests/base_test.php | 4 ++-- + tests/test_repository/autoload_files/object_autoload.php | 5 ----- + tests/test_repository/autoload_files/objet_autoload.php | 5 +++++ + tests/test_repository/object/object.php | 3 ++- + 4 files changed, 9 insertions(+), 8 deletions(-) + delete mode 100644 tests/test_repository/autoload_files/object_autoload.php + create mode 100644 tests/test_repository/autoload_files/objet_autoload.php + +diff --git a/tests/base_test.php b/tests/base_test.php +index 9ab3821..ce410bb 100644 +--- a/tests/base_test.php ++++ b/tests/base_test.php +@@ -424,8 +424,8 @@ public function testBaseAddAndGetAutoloadDirs4() + public function testNoPrefixAutoload() + { + ezcBase::addClassRepository( __DIR__ . '/test_repository', __DIR__ . '/test_repository/autoload_files' ); +- ezc_autoload( 'Object' ); +- if ( !class_exists( 'Object' ) ) ++ ezc_autoload( 'Objet' ); ++ if ( !class_exists( 'Objet' ) ) + { + $this->fail( "Autoload does not handle classes with no prefix" ); + } +diff --git a/tests/test_repository/autoload_files/object_autoload.php b/tests/test_repository/autoload_files/object_autoload.php +deleted file mode 100644 +index 5e3dc90..0000000 +--- a/tests/test_repository/autoload_files/object_autoload.php ++++ /dev/null +@@ -1,5 +0,0 @@ +-<?php +-return array( +- 'Object' => 'object/object.php', +-); +-?> +diff --git a/tests/test_repository/autoload_files/objet_autoload.php b/tests/test_repository/autoload_files/objet_autoload.php +new file mode 100644 +index 0000000..1e81bb0 +--- /dev/null ++++ b/tests/test_repository/autoload_files/objet_autoload.php +@@ -0,0 +1,5 @@ ++<?php ++return array( ++ 'Objet' => 'object/object.php', ++); ++?> +diff --git a/tests/test_repository/object/object.php b/tests/test_repository/object/object.php +index 3b46ba6..6c39fcd 100644 +--- a/tests/test_repository/object/object.php ++++ b/tests/test_repository/object/object.php +@@ -1,4 +1,5 @@ + <?php +-class Object{ ++class Objet{ ++// Objet is not a typo, Object is a reserved keywork in 7.2+ + } + ?> |