[lisaac-Bugs][312096] PB dans SWITCH.

lisaac-bugs at alioth.debian.org lisaac-bugs at alioth.debian.org
Fri Nov 20 15:34:33 UTC 2009


Bugs item #312096, was changed at 20/11/2009 15:30 by Benoit Sonntag
You can respond by visiting: 
https://alioth.debian.org/tracker/?func=detail&atid=413092&aid=312096&group_id=100200

>Status: Closed
Priority: 3
Submitted By: Damien Bouvarel (dams-guest)
Assigned to: Nobody (None)
Summary: PB dans SWITCH. 
Target Milestone: None
Category: Lisaac Compiler


Initial Comment:

Section Header
 + name := BUG;
Section Inherit
 - parent:OBJECT := OBJECT;
Section Public

 - main <-
 ( + b:BOOLEAN;
        
   b := `1`:BOOLEAN;
   b.if {
      "hello".print;
   };
 ); 

With -no_debug it output:  PB dans SWITCH.

In debug mode it compile ok but crash at runtime:

============== BOTTOM ==============
Line #8 Column #8 in BUG (/home/dams/bug.li).
 - main <-
        ^
Line #14 Column #4 in BUG (/home/dams/bug.li).
   };
    ^
Line #62 Column #49 in BOOLEAN (/home/dams/Lisaac/lisaac_0.39_beta/lib/standard/boolean/boolean.li).
  - if true_block:{} :BOOLEAN <- deferred_boolean;
                                                 ^
Line #42 Column #12 in BOOLEAN (/home/dams/Lisaac/lisaac_0.39_beta/lib/standard/boolean/boolean.li).
    deferred;
            ^
================ TOP ===============
Slot deferred.


This kind of code happen in the opengl binding:

      type := `event.type`:INTEGER;

      type
      .when `ClientMessage`:INTEGER then {
      
        (`/* external to see if the event is exit */`:BOOLEAN).if {
	  // stop application
	};	
      };


----------------------------------------------------------------------

>Comment By: Benoit Sonntag (sonntag-guest)
Date: 20/11/2009 16:34

Message:
It's not a bug...
Here, your static type and dynamic type is BOOLEAN.
For to put the different dynamic type's list, you write :

`/* your external */`:BOOLEAN{TRUE,FALSE}

----------------------------------------------------------------------

You can respond by visiting: 
https://alioth.debian.org/tracker/?func=detail&atid=413092&aid=312096&group_id=100200



More information about the Lisaac-devel mailing list