On 21/10/2013 21:36, rpar...@yamiko.org wrote:

This proposal sounds a lot like exceptions to me or am I missing
something :/
Could we do something like throw new expectation($expects, $message);


Er, T_EXPECT will be essentially a clone of Java and Python's assert statement, but not called assert because of the existing assert() function (and backwards-compatibility is PHP's middle name).

Unless you mean the similar name. Well, I don't think "exception" and "expect" can be confused (though as someone who used to use Python, I keep reading this as "except", Python's equivalent to "catch"), though "ExpectationException" might be confusing. I think we should name it "AssertionException".

--
Andrea Faulds
http://ajf.me/

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to