From 397f37e9308c5946fe98229711d19c43421aeee6 Mon Sep 17 00:00:00 2001 From: Eric Stern Date: Thu, 18 Mar 2021 12:25:04 -0700 Subject: [PATCH] Match fgetcsv parameter names to values in reflection The documented parameters differ from the names exposed in reflection/source code. Now that named parameters are supported in PHP 8, this discrepancy is confusing and impactful. ``` $ php --rf fgetcsv Function [ function fgetcsv ] { - Parameters [5] { Parameter #0 [ $stream ] Parameter #1 [ ?int $length = null ] Parameter #2 [ string $separator = "," ] Parameter #3 [ string $enclosure = "\"" ] Parameter #4 [ string $escape = "\\" ] } - Return [ array|false ] } ``` Closes GH-493. --- reference/filesystem/functions/fgetcsv.xml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/reference/filesystem/functions/fgetcsv.xml b/reference/filesystem/functions/fgetcsv.xml index 7dc65c9689..3bb9734ab8 100644 --- a/reference/filesystem/functions/fgetcsv.xml +++ b/reference/filesystem/functions/fgetcsv.xml @@ -10,9 +10,9 @@ &reftitle.description; arrayfgetcsv - resourcehandle + resourcestream intlength0 - stringdelimiter"," + stringseparator"," stringenclosure'"' stringescape"\\" @@ -36,7 +36,7 @@ - handle + stream A valid file pointer to a file successfully opened by @@ -62,10 +62,10 @@ - delimiter + separator - The optional delimiter parameter sets the field delimiter (one character only). + The optional separator parameter sets the field separator (one character only). @@ -117,7 +117,7 @@ ¬e.line-endings; fgetcsv returns &null; if an invalid - handle is supplied or &false; on other errors, + stream is supplied or &false; on other errors, including end of file.