php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #80801 [DE] Wrong "translation": As of PHP 8.0.0, passing optional arguments
Submitted: 2021-02-25 20:14 UTC Modified: 2021-02-26 09:14 UTC
From: ben dot schwarz at nimax dot de Assigned:
Status: Open Package: *Languages/Translation
PHP Version: 8.0.2 OS: -
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: ben dot schwarz at nimax dot de
New email:
PHP Version: OS:

 

 [2021-02-25 20:14 UTC] ben dot schwarz at nimax dot de
Description:
------------
https://www.php.net/manual/de/functions.arguments.php

As of PHP 8.0.0, passing optional arguments after mandatory arguments is deprecated. --> optional and mandatory have to be changed. It was already corrected in the English version, but it seems the German version shows an old copy of the English version.

Should be corrected and maybe translated to DE in that proccess.

---
From manual page: https://php.net/functions.arguments
---


Test script:
---------------
DE wrong:
As of PHP 8.0.0, passing optional arguments after mandatory arguments is deprecated. This can generally be resolved by dropping the default value. One exception to this rule are arguments of the form Type $param = null, where the null default makes the type implicitly nullable. This usage remains allowed, though it is recommended to use an explicit nullable type instead.

Beispiel #3 Passing optional arguments after mandatory arguments

EN correct:
As of PHP 8.0.0, passing mandatory arguments after optional arguments is deprecated. This can generally be resolved by dropping the default value. One exception to this rule are arguments of the form Type $param = null, where the null default makes the type implicitly nullable. This usage remains allowed, though it is recommended to use an explicit nullable type instead.

Example #3 Passing optional arguments after mandatory arguments

Expected result:
----------------
Don't know how the PHP doc works, but it would be much better, if the English original is taken directly instead of creating a copy!


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2021-02-26 09:14 UTC] cmb@php.net
-Summary: Wrong "translation" in German doc: As of PHP 8.0.0, passing optional arguments +Summary: [DE] Wrong "translation": As of PHP 8.0.0, passing optional arguments
 
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Mon Apr 19 18:01:24 2021 UTC