Changeset 97aca3d


Ignore:
Timestamp:
Dec 10, 2020, 4:52:49 PM (3 years ago)
Author:
Thierry Delisle <tdelisle@…>
Branches:
ADT, arm-eh, ast-experimental, enum, forall-pointer-decay, jacob/cs343-translation, master, new-ast-unique-expr, pthread-emulation, qualifiedEnum
Children:
e4b6b7d3
Parents:
80444bb (diff), 3e3f236 (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

Location:
src
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • src/AST/Convert.cpp

    r80444bb r97aca3d  
    233233        const ast::Decl * namedTypePostamble( NamedTypeDecl * decl, const ast::NamedTypeDecl * node ) {
    234234                // base comes from constructor
    235                 decl->parameters = get<TypeDecl>().acceptL( node->params );
    236235                decl->assertions = get<DeclarationWithType>().acceptL( node->assertions );
    237236                declPostamble( decl, node );
     
    17041703                cache.emplace( old, decl );
    17051704                decl->assertions = GET_ACCEPT_V(assertions, DeclWithType);
    1706                 decl->params     = GET_ACCEPT_V(parameters, TypeDecl);
    17071705                decl->extension  = old->extension;
    17081706                decl->uniqueId   = old->uniqueId;
     
    17201718                );
    17211719                decl->assertions = GET_ACCEPT_V(assertions, DeclWithType);
    1722                 decl->params     = GET_ACCEPT_V(parameters, TypeDecl);
    17231720                decl->extension  = old->extension;
    17241721                decl->uniqueId   = old->uniqueId;
  • src/AST/Decl.hpp

    r80444bb r97aca3d  
    154154public:
    155155        ptr<Type> base;
    156         std::vector<ptr<TypeDecl>> params;
    157156        std::vector<ptr<DeclWithType>> assertions;
    158157
     
    160159                const CodeLocation & loc, const std::string & name, Storage::Classes storage,
    161160                const Type * b, Linkage::Spec spec = Linkage::Cforall )
    162         : Decl( loc, name, storage, spec ), base( b ), params(), assertions() {}
     161        : Decl( loc, name, storage, spec ), base( b ), assertions() {}
    163162
    164163        /// Produces a name for the kind of alias
  • src/AST/Pass.impl.hpp

    r80444bb r97aca3d  
    609609        VISIT({
    610610                guard_symtab guard { *this };
    611                 maybe_accept( node, &TypeDecl::params );
    612611                maybe_accept( node, &TypeDecl::base   );
    613612        })
     
    638637        VISIT({
    639638                guard_symtab guard { *this };
    640                 maybe_accept( node, &TypedefDecl::params );
    641639                maybe_accept( node, &TypedefDecl::base   );
    642640        })
  • src/AST/Print.cpp

    r80444bb r97aca3d  
    221221                        ++indent;
    222222                        node->base->accept( *this );
    223                         --indent;
    224                 }
    225 
    226                 if ( ! node->params.empty() ) {
    227                         os << endl << indent << "... with parameters" << endl;
    228                         ++indent;
    229                         printAll( node->params );
    230223                        --indent;
    231224                }
  • src/Common/PassVisitor.impl.h

    r80444bb r97aca3d  
    835835        {
    836836                auto guard = makeFuncGuard( [this]() { indexerScopeEnter(); }, [this]() { indexerScopeLeave(); } );
    837                 maybeAccept_impl( node->parameters, *this );
    838837                maybeAccept_impl( node->base      , *this );
    839838        }
     
    858857        {
    859858                auto guard = makeFuncGuard( [this]() { indexerScopeEnter(); }, [this]() { indexerScopeLeave(); } );
    860                 maybeAccept_impl( node->parameters, *this );
    861859                maybeAccept_impl( node->base      , *this );
    862860        }
     
    880878        {
    881879                auto guard = makeFuncGuard( [this]() { indexerScopeEnter(); }, [this]() { indexerScopeLeave(); } );
    882                 maybeMutate_impl( node->parameters, *this );
    883880                maybeMutate_impl( node->base      , *this );
    884881        }
     
    904901        {
    905902                auto guard = makeFuncGuard( [this]() { indexerScopeEnter(); }, [this]() { indexerScopeLeave(); } );
    906                 maybeAccept_impl( node->parameters, *this );
    907903                maybeAccept_impl( node->base      , *this );
    908904        }
     
    921917        {
    922918                auto guard = makeFuncGuard( [this]() { indexerScopeEnter(); }, [this]() { indexerScopeLeave(); } );
    923                 maybeAccept_impl( node->parameters, *this );
    924919                maybeAccept_impl( node->base      , *this );
    925920        }
     
    938933        {
    939934                auto guard = makeFuncGuard( [this]() { indexerScopeEnter(); }, [this]() { indexerScopeLeave(); } );
    940                 maybeMutate_impl( node->parameters, *this );
    941935                maybeMutate_impl( node->base      , *this );
    942936        }
  • src/Parser/TypeData.cc

    r80444bb r97aca3d  
    900900                ret = new TypeDecl( name, scs, typebuild( td->base ), TypeDecl::Dtype, true );
    901901        } // if
    902         buildList( td->symbolic.params, ret->get_parameters() );
    903902        buildList( td->symbolic.assertions, ret->get_assertions() );
    904903        ret->base->attributes.splice( ret->base->attributes.end(), attributes );
  • src/SynTree/Declaration.h

    r80444bb r97aca3d  
    181181  public:
    182182        Type * base;
    183         std::list< TypeDecl * > parameters;
    184183        std::list< DeclarationWithType * > assertions;
    185184
     
    190189        Type * get_base() const { return base; }
    191190        void set_base( Type * newValue ) { base = newValue; }
    192         std::list< TypeDecl* > & get_parameters() { return parameters; }
    193191        std::list< DeclarationWithType * >& get_assertions() { return assertions; }
    194192
  • src/SynTree/NamedTypeDecl.cc

    r80444bb r97aca3d  
    2929NamedTypeDecl::NamedTypeDecl( const NamedTypeDecl &other )
    3030        : Parent( other ), base( maybeClone( other.base ) ) {
    31         cloneAll( other.parameters, parameters );
    3231        cloneAll( other.assertions, assertions );
    3332}
     
    3534NamedTypeDecl::~NamedTypeDecl() {
    3635        delete base;
    37         deleteAll( parameters );
    3836        deleteAll( assertions );
    3937}
     
    5654                base->print( os, indent+1 );
    5755        } // if
    58         if ( ! parameters.empty() ) {
    59                 os << endl << indent << "... with parameters" << endl;
    60                 printAll( parameters, os, indent+1 );
    61         } // if
    6256        if ( ! assertions.empty() ) {
    6357                os << endl << indent << "... with assertions" << endl;
     
    7670                base->print( os, indent+1 );
    7771        } // if
    78         if ( ! parameters.empty() ) {
    79                 os << endl << indent << "... with parameters" << endl;
    80                 printAll( parameters, os, indent+1 );
    81         } // if
    8272}
    8373
Note: See TracChangeset for help on using the changeset viewer.