[Laszlo-dev] For Review: Change 20081017-ptw-z Summary: Fix class compilation and forward references in binary libraries

André Bargull andre.bargull at udo.edu
Sun Oct 19 04:29:40 PDT 2008


There is still an issue with loadable snippets and compiled libraries.
When replaced the <include> with an <import>-tag, I got the following error:
> <a title="#0">ERROR: reference to undefined variable '$lzc$class_pak'</a>
> ERROR: Class undefined has not been defined yet

I've verified that this worked in OL4.0.9.


new main-file:
> <canvas width="100%" height="100%" bgcolor="gray" debug="true">
>   <import name="lib" stage="defer" href="pak.lzx" />
>   <simplelayout />
>   <handler name="oninit">
>     lib.load();
>   </handler>
>   <handler name="onload" reference="lib" >
>     canvas.showlater.apply();
>   </handler>
>   <state name="showlater" applied="false" >
>     <pak>Main</pak>
>   </state>
> </canvas>



On 10/18/2008 4:05 AM, P T Withington wrote:
> Change 20081017-ptw-z by ptw at dueling-banjos.local on 2008-10-17 
> 18:06:41 EDT
>     in /Users/ptw/OpenLaszlo/trunk
>     for http://svn.openlaszlo.org/openlaszlo/trunk
>
> Summary: Fix class compilation and forward references in binary libraries
>
> Bugs Fixed:
> LPP-6726  Binary compilation (LPS 4.1+)
>
> Technical Reviewer: a.bargull at intensis.de (pending)
> QA Reviewer: pbr (pending)
>
> Details:
>     ViewSchema: Only emit schema for modelled and compiled nodes.
>
>     Compiler: Dynamically bind the environment option $externalLibrary
>     when parsing external libraries, so...
>
>     ClassModel: You can note classes defined in external libraries to
>     be modelled only, not compiled.  Only emit class declarations when
>     a class is not from an external library and either required by a
>     reference to it or defined in the compilation unit.
>
> Tests:
>     smokecheck, test case from bug
>
> Files:
> M      WEB-INF/lps/server/src/org/openlaszlo/compiler/ViewSchema.java
> M      WEB-INF/lps/server/src/org/openlaszlo/compiler/Compiler.java
> M      WEB-INF/lps/server/src/org/openlaszlo/compiler/ClassModel.java
>
> Changeset: 
> http://svn.openlaszlo.org/openlaszlo/patches/20081017-ptw-z.tar
>


More information about the Laszlo-dev mailing list