コード例 #1
0
static TYPE *enumConst(char *buf, TYPE *tp)
{
    while (tp && (isconst(tp) || isvolatile(tp) || isrestrict(tp) || tp->type == bt_derivedfromtemplate))
    {
        switch(tp->type)
        {
            case bt_lrqual:
                strcat(buf, "& ");
                break;
            case bt_rrqual:
                strcat(buf, "&& ");
                break;
            case bt_const:
                strcat(buf, tn_const);
                break;
            case bt_volatile:
                strcat(buf, tn_volatile);
                break;
            case bt_restrict:
            case bt_derivedfromtemplate:
/*				strcat(buf, tn_restrict); */
                break;
            default:
                break;
        }
        tp = tp->btp;
    }
    return tp;
}
コード例 #2
0
ファイル: types.c プロジェクト: jossk/OrangeC
static TYPE *enumConst(char *buf, TYPE *tp)
{
    while (isconst(tp) || isvolatile(tp) || isrestrict(tp))
    {
        switch(tp->type)
        {
            case bt_const:
                strcat(buf, tn_const);
                break;
            case bt_volatile:
                strcat(buf, tn_volatile);
                break;
            case bt_restrict:
/*				strcat(buf, tn_restrict); */
                break;
        }
        tp = tp->btp;
    }
    return tp;
}