Thanks, and sorry for the delay on the review (just sent, approved
with comments).
I think I'll wait for you to do 'as' and then I'll merge to devildog
and do anything needed for SWF9 for is/as.
On Jan 8, 2008, at 9:13 AM, P T Withington wrote:
I checked this in so I can start on LPP-5336. If you have comments,
I will address them in a subsequent patch. When I finish 5336, you
should integrate from trunk to devildog.
On 2008-01-07, at 16:10 EST, P T Withington wrote:
Change 20080107-ptw-n by [EMAIL PROTECTED] on 2008-01-07
15:41:52 EST
in /Users/ptw/OpenLaszlo/ringding-2
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: Implement `is` operator
Bugs Fixed:
LPP-3632 'Implement `is` operator'
Technical Reviewer: [EMAIL PROTECTED] (pending)
QA Reviewer: [EMAIL PROTECTED] (pending)
Doc Reviewer: [EMAIL PROTECTED] (pending)
Documentation:
We now implement the ECMAScript 4 `is` operator
Details:
lztest-class-impl: Use modern syntax, verify that `is` is
equivalent to `instanceof` and works properly for mixins.
Class: add runtime support for `is` operator on mixins
JavascriptGenerator, CodeGenerator, ParseTreePrinter, Parser: Add
support for `is` operator, which in JS1 runtimes is approximated
as: a is b => b['$lzsc$isa'] ? b.$lzsc$isa(a) : (a instanceof b),
relying on the runtime support in Class for $lzsc$isa.
ASTVisitor: remove the unused visitBinaryExpression
Tests:
Amended class-impl test to test that `is` is equivalent to
`instanceof` for classes and works properly for mixins.
Files:
M test/lztest/lztest-class-impl.lzx
M WEB-INF/lps/lfc/compiler/Class.lzs
M WEB-INF/lps/server/src/org/openlaszlo/sc/
JavascriptGenerator.java
M WEB-INF/lps/server/src/org/openlaszlo/sc/ASTVisitor.java
M WEB-INF/lps/server/src/org/openlaszlo/sc/CodeGenerator.java
M WEB-INF/lps/server/src/org/openlaszlo/sc/ParseTreePrinter.java
M WEB-INF/lps/server/sc/src/org/openlaszlo/sc/Parser.jjt
Changeset: http://svn.openlaszlo.org/openlaszlo/patches/20080107-ptw-n.tar
--
Don Anderson
Java/C/C++, Berkeley DB, systems consultant
voice: 617-547-7881
email: [EMAIL PROTECTED]
www: http://www.ddanderson.com