FormatJson: minor cleanup
authorKevin Israel <pleasestand@live.com>
Tue, 8 Oct 2013 14:52:01 +0000 (10:52 -0400)
committerKevin Israel <pleasestand@live.com>
Tue, 8 Oct 2013 22:28:09 +0000 (18:28 -0400)
commit39e22628f7c8dfeaff522c6a0ca06c0899743ff7
tree4c9ee11794fff2fa14201e1e63c0091485dcf2bb
parent0d0bfbf253056e237aedb456fbf4059fed62d8c3
FormatJson: minor cleanup

* Prefer feature detection over version comparison.
* Prefer pre- over post- increment and decrement operators.
* Remove the statement that FormatJson::decode() decodes `true`,
  `false`, and `null` case insensitively. Nobody should assume
  this is (or is not) the case, even though the PHP manual says so.
* Avoid using the ternary operator with long strings; prior to
  PHP 5.4, the operator prevented the copy-on-write optimization.
* Avoid placing comments on the same lines as code.

Change-Id: I8fc88e9b7b49aa0cbd4128216557836a3b2cd011
includes/json/FormatJson.php