Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/app/sbi/src/stree.c

    r051bc69a rc5cb943d  
    9292        csi->ancr_state = ws_unvisited;
    9393        csi->name = NULL;
    94         csi->base_csi_ref = NULL;
     94        csi->base_csi = NULL;
     95        list_init(&csi->inherit);
     96        list_init(&csi->impl_if_ti);
    9597        list_init(&csi->members);
     98
    9699        return csi;
    97100}
     
    930933
    931934        symbol->sc = sc;
     935        list_init(&symbol->attr);
     936
    932937        return symbol;
    933938}
     
    10181023
    10191024        /* We went all the way to the root and did not find b. */
     1025        return b_false;
     1026}
     1027
     1028/** Determine if @a symbol is static.
     1029 *
     1030 * @param symbol        Symbol
     1031 * @return              @c b_true if symbol is static, @c b_false otherwise
     1032 */
     1033bool_t stree_symbol_is_static(stree_symbol_t *symbol)
     1034{
     1035        /* Module-wide symbols are static. */
     1036        if (symbol->outer_csi == NULL)
     1037                return b_true;
     1038
     1039        /* Symbols with @c static attribute are static. */
     1040        if (stree_symbol_has_attr(symbol, sac_static))
     1041                return b_true;
     1042
     1043        switch (symbol->sc) {
     1044        case sc_csi:
     1045        case sc_deleg:
     1046        case sc_enum:
     1047                return b_true;
     1048        case sc_ctor:
     1049        case sc_fun:
     1050        case sc_var:
     1051        case sc_prop:
     1052                break;
     1053        }
     1054
    10201055        return b_false;
    10211056}
Note: See TracChangeset for help on using the changeset viewer.