Ignore:
Timestamp:
May 28, 2024, 11:38:25 AM (3 months ago)
Author:
Andrew Beach <ajbeach@…>
Branches:
master
Children:
91b9e10
Parents:
66286aa
Message:

Simplified the visit children guard to use a ValueGuardPtr?. For consistency, so all three guards use the same pattern, I also updated the value guard, which is a side ways step in complexity (although less of it is under macros now).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/AST/Pass.impl.hpp

    r66286aa r96c04e4  
    2727        using namespace ast; \
    2828        /* back-up the last known code location */ \
    29         __attribute__((unused)) auto loc_guard = ast::__pass::make_location_guard( core, node, 0 ); \
     29        __attribute__((unused)) auto guard0 = __pass::make_location_guard( core, node, 0 ); \
    3030        /* back-up the visit children */ \
    31         __attribute__((unused)) ast::__pass::visit_children_guard guard1( ast::__pass::visit_children(core, 0) ); \
     31        __attribute__((unused)) auto guard1 = __pass::make_visit_children_guard( core, 0 ); \
    3232        /* setup the scope for passes that want to run code at exit */ \
    33         __attribute__((unused)) ast::__pass::guard_value          guard2( ast::__pass::at_cleanup    (core, 0) ); \
     33        __attribute__((unused)) auto guard2 = __pass::make_value_guard( core, 0 ); \
    3434        /* begin tracing memory allocation if requested by this pass */ \
    3535        __pass::beginTrace( core, 0 ); \
Note: See TracChangeset for help on using the changeset viewer.