Changeset 1992


Ignore:
Timestamp:
Jun 15, 2006, 3:52:50 AM (15 years ago)
Author:
orlov
Message:
  • iter, lsplit, and rsplit are renamed to RF_iter, RF_lsplit, and RF_rsplit.
  • Create refal-characters from wchar_t literals when possible.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • to-imperative/trunk/compiler/rfp_asail_cpp.rf

    r1912 r1992  
    170170      ('RF_FUNC_ERROR (unexpected_fail);');
    171171    (LSPLIT e.expr (e.min) t.var1 t.var2) =
    172       ('lsplit (' <Expr-Ref-To-CPP e.expr> ', ' <Expr-Int-To-CPP e.min> ', '
     172      ('RF_lsplit (' <Expr-Ref-To-CPP e.expr> ', ' <Expr-Int-To-CPP e.min> ', '
    173173      <Rfp2Cpp t.var1> ', ' <Rfp2Cpp t.var2> ');');
    174174    (RSPLIT e.expr (e.min) t.var1 t.var2) =
    175       ('rsplit (' <Expr-Ref-To-CPP e.expr> ', ' <Expr-Int-To-CPP e.min> ', '
     175      ('RF_rsplit (' <Expr-Ref-To-CPP e.expr> ', ' <Expr-Int-To-CPP e.min> ', '
    176176      <Rfp2Cpp t.var1> ', ' <Rfp2Cpp t.var2 > ');');
    177177    (ASSIGN t.var e.expr) =
    178178      (<Rfp2Cpp t.var> ' = ' <Expr-To-CPP () e.expr> ';');
    179179    (DECL s.type t.var) =
    180       (s.type ' ' <Rfp2Cpp t.var> ';');
     180      ('Expr ' <Rfp2Cpp t.var> ';');
    181181    (INT  t.var e.expr) =
    182182      ('uintptr_t ' <Rfp2Cpp t.var> ' = ' <Expr-Int-To-CPP e.expr> ';');
     
    216216        s.tag : BOX =
    217217          <Put &Const-Exprs (e.cpp-name
    218             ('Expr::create_sym< NamedObject<BoxContents> >(L"'e.name'")'))>;
     218            ('Expr::create_sym< rftype::NamedObject<rftype::BoxContents> >('
     219              'L"'e.name'")'))>;
     220//        s.tag : VECTOR =
     221//          <Put &Const-Exprs (e.cpp-name
     222//            ('Expr::create_sym< rftype::NamedObject<rftype::Vector> >('
     223//              'L"'e.name'")'))>;
    219224        <Put &Const-Exprs (e.cpp-name
    220225          ('new rftype::StaticObject<rftype::' s1 <To-Lower e2> '>(L"'e.name'")'))>;
     
    341346      <Expr-Int-To-CPP e.pos> ', ' <Expr-Int-To-CPP e.len> ')';
    342347  (CHECK-ITER e.expr) =
    343     'iter(' <Expr-Ref-To-CPP e.expr> ')';
     348    'RF_iter(' <Expr-Ref-To-CPP e.expr> ')';
    344349  (EQ e.expr1 (e.expr2) (e.pos)) =
    345350    <Expr-Ref-To-CPP e.expr1> '.eq ('
     
    374379Step-To-CPP {
    375380  /*empty*/ = /*empty*/;
    376   (INC-ITER e.expr) = 'iter(' <Expr-Ref-To-CPP e.expr> ')++';
    377   (DEC-ITER e.expr) = 'iter(' <Expr-Ref-To-CPP e.expr> ')--';
     381  (INC-ITER e.expr) = 'RF_iter(' <Expr-Ref-To-CPP e.expr> ')++';
     382  (DEC-ITER e.expr) = 'RF_iter(' <Expr-Ref-To-CPP e.expr> ')--';
    378383};
    379384
     
    399404    <Const-Expr-Aux (e.accum <Symbol-To-CPP s.sym>) e.rest>;
    400405  e.accum : v =
    401     ' + Char::create_expr ("' e.accum '")' <Const-Expr-Aux () e.expr>;
     406    {
     407      <Chars-To-Bytes e.accum> : e s.c e,
     408        <">" (s.c) (127)> =
     409        ' + Char::create_expr ("' e.accum '")' <Const-Expr-Aux () e.expr>;
     410      //' + Expr::create_seq<Char> (L"' e.accum '")' <Const-Expr-Aux () e.expr>;
     411      ' + Char::create_expr (L"' e.accum '")' <Const-Expr-Aux () e.expr>;
     412    };
    402413  e.expr : t.item e.rest, t.item : {
    403414    (PAREN e.paren-expr) =
Note: See TracChangeset for help on using the changeset viewer.