Ignore:
Timestamp:
2010-05-08T08:15:57Z (15 years ago)
Author:
Jiri Svoboda <jiri@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
4039c77
Parents:
1317380 (diff), 051bc69a (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge from lp:~jsvoboda/helenos/sysel. New: cspan printing, boolean ops, enums, constructors etc.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/app/sbi/src/builtin/bi_textfile.c

    r1317380 r640ffe6  
    7171                        "fun WriteLine(line : string), builtin;\n"
    7272                        "\n"
    73                         "prop EOF : int is\n"
     73                        "prop EOF : bool is\n"
    7474                                "get is\n"
    7575                                        "return is_eof();\n"
     
    7777                        "end\n"
    7878                        "\n"
    79                         "fun is_eof() : int, builtin;\n"
     79                        "fun is_eof() : bool, builtin;\n"
    8080                "end\n");
    8181
     
    342342        rdata_var_t *self_f_var;
    343343
    344         int eof_flag;
    345         rdata_int_t *eof_int;
     344        bool_t eof_flag;
     345        rdata_bool_t *eof_bool;
    346346        rdata_var_t *eof_var;
    347347        rdata_value_t *eof_val;
     
    362362        /* Get status of EOF flag. */
    363363
    364         eof_flag = feof(file) ? 1 : 0;
    365 
    366 #ifdef DEBUG_RUN_TRACE
    367         printf("Read EOF flag '%d'.\n", eof_flag);
     364        eof_flag = feof(file) ? b_true : b_false;
     365
     366#ifdef DEBUG_RUN_TRACE
     367        printf("Read EOF flag '%s'.\n", eof_flag ? "true" : "false");
    368368#endif
    369369        /* Construct return value. */
    370         eof_int = rdata_int_new();
    371         bigint_init(&eof_int->value, eof_flag);
    372 
    373         eof_var = rdata_var_new(vc_int);
    374         eof_var->u.int_v = eof_int;
     370        eof_bool = rdata_bool_new();
     371        eof_bool->value = eof_flag;
     372
     373        eof_var = rdata_var_new(vc_bool);
     374        eof_var->u.bool_v = eof_bool;
    375375        eof_val = rdata_value_new();
    376376        eof_val->var = eof_var;
Note: See TracChangeset for help on using the changeset viewer.