On Thu, Mar 15, 2018 at 10:39 AM, David Causse <dcausse(a)wikimedia.org>
wrote:
The biggest take-away (for me) of the discussion is:
Pros:
- perf: zero-cost assertions
Cons:
- the benefits of zero-cost assertion is not worth the risk in a moving
code-base like MW.
The biggest take-away for me from the discussions is that PHP5 assert()'s
reliance on eval()-like operation is bad in a number of ways, and the weird
behavior of issuing a warning and then exiting is weird.
PHP7's expectations seem like they started fixing those issues, although
eval()-like use is still an option and exception-throwing seems to not be
the default.
--
Brad Jorsch (Anomie)
Senior Software Engineer
Wikimedia Foundation