Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/SymTab/GenImplicitCall.cpp

    r14c0f7b r8913de4  
    1616#include "GenImplicitCall.hpp"
    1717
    18 #include "AST/Copy.hpp"                  // for deepCopy
    1918#include "AST/Decl.hpp"                  // for ObjectDecl
    2019#include "AST/Expr.hpp"                  // for ConstantExpr, UntypedExpr,...
     
    116115        std::string cmp, update;
    117116
    118         const ast::Expr * dimension = deepCopy( array->dimension );
    119117        if ( forward ) {
    120118                // generate: for ( int i = 0; i < N; ++i )
    121119                begin = ast::ConstantExpr::from_int( loc, 0 );
    122                 end = dimension;
     120                end = array->dimension;
    123121                cmp = "?<?";
    124122                update = "++?";
     
    126124                // generate: for ( int i = N-1; i >= 0; --i )
    127125                begin = ast::UntypedExpr::createCall( loc, "?-?",
    128                         { dimension, ast::ConstantExpr::from_int( loc, 1 ) } );
     126                        { array->dimension, ast::ConstantExpr::from_int( loc, 1 ) } );
    129127                end = ast::ConstantExpr::from_int( loc, 0 );
    130128                cmp = "?>=?";
Note: See TracChangeset for help on using the changeset viewer.