Doc #80553 [NEW]: `json_decode()`-documentation has false information

From: Date: Sat, 26 Dec 2020 19:53:05 +0000
Subject: Doc #80553 [NEW]: `json_decode()`-documentation has false information
Groups: php.doc.bugs 
Request: Send a blank email to doc-bugs+get-18318@lists.php.net to get a copy of this message
From:             lars at lquenti dot de
Operating system: Arch
PHP version:      7.3.25
Package:          Documentation problem
Bug Type:         Documentation Problem
Bug description:json_decode()-documentation has false information

Description:
------------
The documentation https://www.php.net/manual/en/function.json-decode.php
mentions the following:

Values true, false and null are returned as true, false and null
respectively.

As shown in the test script, json_decode(false) returns null instead
of false.
json_decode(true) works as expected.

Test script:
---------------
<?php echo is_null(json_decode(false)) ?>


-- 
Edit bug report at https://bugs.php.net/bug.php?id=80553&edit=1
-- 
Fix committed:                    https://bugs.php.net/fix.php?id=80553&r=fixed
Fixed in release:                 https://bugs.php.net/fix.php?id=80553&r=alreadyfixed
Need backtrace:                   https://bugs.php.net/fix.php?id=80553&r=needtrace
Need Reproduce Script:            https://bugs.php.net/fix.php?id=80553&r=needscript
Try newer version:                https://bugs.php.net/fix.php?id=80553&r=oldversion
Not developer issue:              https://bugs.php.net/fix.php?id=80553&r=support
Expected behavior:                https://bugs.php.net/fix.php?id=80553&r=notwrong
Not enough info:                  https://bugs.php.net/fix.php?id=80553&r=notenoughinfo
Submitted twice:                  https://bugs.php.net/fix.php?id=80553&r=submittedtwice
register_globals:                 https://bugs.php.net/fix.php?id=80553&r=globals
PHP version support discontinued: https://bugs.php.net/fix.php?id=80553&r=phptooold
Daylight Savings:                 https://bugs.php.net/fix.php?id=80553&r=dst
IIS Stability:                    https://bugs.php.net/fix.php?id=80553&r=isapi
Install GNU Sed:                  https://bugs.php.net/fix.php?id=80553&r=gnused
Floating point limitations:       https://bugs.php.net/fix.php?id=80553&r=float
No Zend Extensions:               https://bugs.php.net/fix.php?id=80553&r=nozend
MySQL Configuration Error:        https://bugs.php.net/fix.php?id=80553&r=mysqlcfg


Thread (3 messages)

« previous php.doc.bugs (#18318) next »