At 02:39 PM 2/16/2006, Sara Golemon wrote:
I gave this some thought as I was designing the overloading approach. I didn't go there because I actually wanted to allow asymmetry between the operands as sometimes communative properties don't apply cleanly. Most obviously in the case of sub/div ops, but also in certain other (less likely) spots like matrix maths. a[1,3] * b[3,1] is certainly different than b[3,1] * a[1,3].
True.
I'll take a look at applying this to the is_smaller op at least. I'm not a master mathematician, but I'm fairly certain that 2 is always greater than 1.(Cue the cue the internals@ response to the contrary) > We could possibly split that into two opcodes for PHP 6 mainly as a > "documentation" feature of the source code so less is lost during the compile. > That would certainly address PECL/operator's needs and only costs the engine in the form of a slightly increased binary (which the extval hack does anyway).
Yeah, well let's see if we can find some other compelling reasons to possible make the change for PHP 6. In the meantime, I think providing the patch with your extension should be OK. A hack for a hack :)
Andi
-- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php