Ignore:
Timestamp:
Aug 13, 2024, 9:17:26 AM (3 months ago)
Author:
Peter A. Buhr <pabuhr@…>
Branches:
master
Children:
4941716
Parents:
f9b42bd (diff), 97f8f0f (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 branch 'master' of plg.uwaterloo.ca:software/cfa/cfa-cc

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/GenPoly/Lvalue.cpp

    rf9b42bd rdee680c  
    1010// Created On       : Thu Sep 15 14:08:00 2022
    1111// Last Modified By : Andrew Beach
    12 // Last Modified On : Wed Oct  6  9:59:00 2022
    13 // Update Count     : 0
     12// Last Modified On : Mon Aug 12 18:07:00 2024
     13// Update Count     : 1
    1414//
    1515
     
    119119/// Replace all reference types with pointer types.
    120120struct ReferenceTypeElimination final {
     121        ast::SizeofExpr const * previsit( ast::SizeofExpr const * expr );
     122        ast::AlignofExpr const * previsit( ast::AlignofExpr const * expr );
    121123        ast::Type const * postvisit( ast::ReferenceType const * type );
    122124};
     
    603605}
    604606
     607ast::SizeofExpr const * ReferenceTypeElimination::previsit(
     608                ast::SizeofExpr const * expr ) {
     609        if ( expr->expr ) return expr;
     610        return ast::mutate_field( expr, &ast::SizeofExpr::type,
     611                expr->type->stripReferences() );
     612}
     613
     614ast::AlignofExpr const * ReferenceTypeElimination::previsit(
     615                ast::AlignofExpr const * expr ) {
     616        if ( expr->expr ) return expr;
     617        return ast::mutate_field( expr, &ast::AlignofExpr::type,
     618                expr->type->stripReferences() );
     619}
     620
    605621ast::Type const * ReferenceTypeElimination::postvisit(
    606622                ast::ReferenceType const * type ) {
Note: See TracChangeset for help on using the changeset viewer.