lotus



previous page: C11.1.1) Static Constants
  
page up: BETA Programming Language FAQ
  
next page: C11.1.3) "T1PROGRAM undefined" reported by the linker

C11.1.2) Computed remotes and virtuals




Description

This article is from the FAQ, by with numerous contributions by others.

C11.1.2) Computed remotes and virtuals

The computed remotes, that the compiler supports in general from release
v5.0, will sometimes make the compiler crash, especially if virtuals are
involved. Example:

   ORIGIN '~beta/basiclib/current/betaenv';
   INCLUDE '~beta/containers/current/list';
   --- program: descriptor ---
   (# point: (# x: @integer; #);
      pointList: @List
        (# element::point;
           headx: (# exit (head).elm.x #);
        #);
   #)

This program makes the compiler crash with the error:

   ******* System error!!!
   Pre is empty/null(virtual binding)
   Please report this error to Mjolner Informatics

The workaround in this case is to avoid the computed remote in headx:

   ORIGIN '~beta/basiclib/current/betaenv';
   INCLUDE '~beta/containers/current/list';
   --- program: descriptor ---
   (# point: (# x: @integer; #);
      pointList: @List
        (# element::point;
           thehead: ^theCellType;
           headx: (# do head->thehead[]; exit thehead.elm.x #);
        #);
   #)

 

Continue to:















TOP
previous page: C11.1.1) Static Constants
  
page up: BETA Programming Language FAQ
  
next page: C11.1.3) "T1PROGRAM undefined" reported by the linker