Changeset 94d484a in mainline for uspace/app/sbi/src/stree_t.h


Ignore:
Timestamp:
2010-03-07T17:45:33Z (14 years ago)
Author:
Jiri Svoboda <jiri@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
d0febca
Parents:
fa36f29
Message:

Update SBI to rev. 90.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/app/sbi/src/stree_t.h

    rfa36f29 r94d484a  
    151151} stree_assign_t;
    152152
     153/** Indexing operation */
     154typedef struct {
     155        /** Base */
     156        struct stree_expr *base;
     157
     158        /** Arguments (indices) */
     159        list_t args; /* of stree_expr_t */
     160} stree_index_t;
     161
    153162/** Arithmetic expression class */
    154163typedef enum {
     
    161170        ec_access,
    162171        ec_call,
    163         ec_assign
     172        ec_assign,
     173        ec_index
    164174} expr_class_t;
    165175
     
    177187                stree_access_t *access;
    178188                stree_call_t *call;
     189                stree_index_t *index;
    179190                stree_assign_t *assign;
    180191        } u;
     
    217228} stree_tapply_t;
    218229
     230/** Type index operation */
     231typedef struct {
     232        /** Base type */
     233        struct stree_texpr *base_type;
     234
     235        /**
     236         * Number of arguments (rank). Needed when only rank is specified
     237         * and @c args are not used.
     238         */
     239        int n_args;
     240
     241        /** Arguments (extents) */
     242        list_t args; /* of stree_expr_t */
     243} stree_tindex_t;
     244
    219245/** Type expression class */
    220246typedef enum {
     
    222248        tc_tnameref,
    223249        tc_taccess,
    224         tc_tapply
     250        tc_tapply,
     251        tc_tindex
    225252} texpr_class_t;
    226253
     
    234261                stree_taccess_t *taccess;
    235262                stree_tapply_t *tapply;
     263                stree_tindex_t *tindex;
    236264        } u;
    237265} stree_texpr_t;
     
    252280        stree_texpr_t *type;
    253281} stree_vdecl_t;
     282
     283/** @c except clause */
     284typedef struct {
     285        stree_ident_t *evar;
     286        stree_texpr_t *etype;
     287        stree_block_t *block;
     288} stree_except_t;
    254289
    255290/** If statement */
     
    273308/** Raise statement */
    274309typedef struct {
     310        stree_expr_t *expr;
    275311} stree_raise_t;
    276312
     
    288324typedef struct {
    289325        stree_block_t *with_block;
    290         list_t except_blocks; /* of stree_block_t */
     326        list_t except_clauses; /* of stree_except_t */
    291327        stree_block_t *finally_block;
    292328} stree_wef_t;
     329
    293330
    294331/** Statement class */
     
    320357} stree_stat_t;
    321358
     359/** Argument attribute class */
     360typedef enum {
     361        /** Packed argument (for variadic functions) */
     362        aac_packed
     363} arg_attr_class_t;
     364
     365/** Argument atribute */
     366typedef struct {
     367        arg_attr_class_t aac;
     368} stree_arg_attr_t;
     369
    322370/** Formal function parameter */
    323371typedef struct {
     
    327375        /* Argument type */
    328376        stree_texpr_t *type;
     377
     378        /* Attributes */
     379        list_t attr; /* of stree_arg_attr_t */
    329380} stree_fun_arg_t;
    330381
     
    339390        /** Formal parameters */
    340391        list_t args; /* of stree_fun_arg_t */
     392
     393        /** Variadic argument or @c NULL if none. */
     394        stree_fun_arg_t *varg;
    341395
    342396        /** Return type */
     
    400454        stree_texpr_t *base_csi_ref;
    401455
     456        /** Base CSI. Only available when ancr_state == ws_visited. */
     457        struct stree_csi *base_csi;
     458
    402459        /** Node state for ancr walks. */
    403460        walk_state_t ancr_state;
Note: See TracChangeset for help on using the changeset viewer.