Changes between Version 20 and Version 21 of CIVLite


Ignore:
Timestamp:
03/24/24 14:56:22 (2 years ago)
Author:
siegel
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • CIVLite

    v20 v21  
    33Emphasis on performance and parallelization (using C11 threads?).
    44
    5 Types are: ints, proc, and arrays of any type.
     5Types are: ints, proc, string, and arrays of any type.
    66
    77Identifiers all start with `%`.
     
    2222constant: INT | 'null'
    2323string: '"' .* '"'
    24 type: 'int' | 'proc' | type[]
     24type: 'int' | 'proc' | 'string' | type[]
    2525typedvar: type ID
    2626paramdecl: 'param' typedvar ('=' expr)? ';'
     
    3737       | return | wait | assert | print
    3838assign: lval '=' expr
    39 invocation: ID '(' exprlist? ')'
     39invocation: ID '(' exprlst? ')'
    4040call: (lval '=')? 'call' invocation
    4141spawn: (lval '=')? 'spawn' invocation
     
    4343wait : 'wait' expr
    4444assert: 'assert' expr
    45 print: 'print' exprstrlst
    46 exprstrlst: exprstr (',' exprstr)*
    47 exprstr: expr | string
    48 exprlist: expr (',' expr)*
     45print: 'print' exprlst
     46exprlst: expr (',' expr)*
    4947lval: ID | lval '[' expr ']'
    5048
    51 expr: lval | constant | '(' expr ')' | expr '+' expr | ... // + - * / mod  - == != >= > < <= && || !
     49expr: lval | constant | string |  '(' expr ')' | expr '+' expr
     50  | ... // + - * / mod  - == != >= > < <= && || ! ...
    5251  | 'ite' '(' expr ',' expr ',' expr ')'
    5352  | '(' type ')' 'array' '(' expr ',' expr ')' // (T[])array(length, value)