From cf04609ce50f0fb89715dc58469486c502cb3a25 Mon Sep 17 00:00:00 2001 From: Jeremy Mikola Date: Fri, 27 Feb 2015 21:48:00 +0000 Subject: [PATCH] SplFileInfo class setters allow and default to base class These methods allow (and default to) the base class. The previous documentation made it seem as if only child classes were accepted as an argument and also did not clarify the default value. That likely resulted in the following HHVM implementation difference: https://github.com/facebook/hhvm/pull/4917 git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@336017 c90b9560-bf6c-de11-be94-00142212c4b1 --- reference/spl/splfileinfo/setfileclass.xml | 5 +++-- reference/spl/splfileinfo/setinfoclass.xml | 5 +++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/reference/spl/splfileinfo/setfileclass.xml b/reference/spl/splfileinfo/setfileclass.xml index 92ec73dd33..4da8e1fe96 100644 --- a/reference/spl/splfileinfo/setfileclass.xml +++ b/reference/spl/splfileinfo/setfileclass.xml @@ -11,11 +11,12 @@ &reftitle.description; public voidSplFileInfo::setFileClass - stringclass_name + stringclass_name"SplFileObject" Set the class name which SplFileInfo will use to open files with when openFile() is called. - The class name passed to this method must be derived from SplFileObject. + The class name passed to this method must be SplFileObject or a class derived + from SplFileObject. diff --git a/reference/spl/splfileinfo/setinfoclass.xml b/reference/spl/splfileinfo/setinfoclass.xml index f1620f712d..ab9683c1b1 100644 --- a/reference/spl/splfileinfo/setinfoclass.xml +++ b/reference/spl/splfileinfo/setinfoclass.xml @@ -11,12 +11,13 @@ &reftitle.description; public voidSplFileInfo::setInfoClass - stringclass_name + stringclass_name"SplFileInfo" Use this method to set a custom class which will be used when getFileInfo and getPathInfo are called. - The class name passed to this method must be derived from SplFileInfo. + The class name passed to this method must be SplFileInfo or a class derived + from SplFileInfo.