Changeset 454b4e0 for src


Ignore:
Timestamp:
Feb 9, 2022, 10:59:11 PM (4 years ago)
Author:
Peter A. Buhr <pabuhr@…>
Branches:
ADT, ast-experimental, enum, forall-pointer-decay, master, pthread-emulation, qualifiedEnum
Children:
6a823241
Parents:
12b5e94a (diff), a986807 (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:
5 edited

Legend:

Unmodified
Added
Removed
  • src/AST/Pass.hpp

    r12b5e94a r454b4e0  
    265265        result1<ast::Stmt> call_accept_as_compound(const ast::Stmt *);
    266266
    267         template<typename it_t, template <class...> class container_t>
    268                 static inline void take_all_delta( it_t it, container_t<ast::ptr<ast::Decl>> * decls, bool * mutated = nullptr ) {
    269                         if(empty(decls)) return;
    270 
    271                         std::transform(decls->begin(), decls->end(), it, [](ast::ptr<ast::Decl>&& decl) -> auto {
    272                                         auto loc = decl->location;
    273                                         auto stmt = new DeclStmt( loc, decl.release() );
    274                                         return { {stmt}, -1, false };
    275                                 });
    276                         decls->clear();
    277                         if(mutated) *mutated = true;
    278                 }
    279 
    280267        // Container of statements
    281268        template< template <class...> class container_t >
  • src/AST/Pass.impl.hpp

    r12b5e94a r454b4e0  
    160160
    161161        template< typename core_t >
    162         ast::Pass< core_t >::result1<ast::Expr> ast::Pass< core_t >::call_accept( const ast::Expr * expr ) {
     162        typename ast::Pass< core_t >::template result1<ast::Expr> ast::Pass< core_t >::call_accept( const ast::Expr * expr ) {
    163163                __pedantic_pass_assert( __visit_children() );
    164164                __pedantic_pass_assert( expr );
     
    174174
    175175        template< typename core_t >
    176         ast::Pass< core_t >::result1<ast::Stmt> ast::Pass< core_t >::call_accept( const ast::Stmt * stmt ) {
     176        typename ast::Pass< core_t >::template result1<ast::Stmt> ast::Pass< core_t >::call_accept( const ast::Stmt * stmt ) {
    177177                __pedantic_pass_assert( __visit_children() );
    178178                __pedantic_pass_assert( stmt );
     
    183183
    184184        template< typename core_t >
    185         ast::Pass< core_t >::result1<ast::Stmt> ast::Pass< core_t >::call_accept_as_compound( const ast::Stmt * stmt ) {
     185        typename ast::Pass< core_t >::template result1<ast::Stmt> ast::Pass< core_t >::call_accept_as_compound( const ast::Stmt * stmt ) {
    186186                __pedantic_pass_assert( __visit_children() );
    187187                __pedantic_pass_assert( stmt );
     
    258258        template< typename core_t >
    259259        template< template <class...> class container_t >
    260         ast::Pass< core_t >::resultNstmt<container_t> ast::Pass< core_t >::call_accept( const container_t< ptr<Stmt> > & statements ) {
     260        typename ast::Pass< core_t >::template resultNstmt<container_t> ast::Pass< core_t >::call_accept( const container_t< ptr<Stmt> > & statements ) {
    261261                __pedantic_pass_assert( __visit_children() );
    262262                if( statements.empty() ) return {};
     
    346346        template< typename core_t >
    347347        template< template <class...> class container_t, typename node_t >
    348         ast::Pass< core_t >::resultN<container_t, node_t> ast::Pass< core_t >::call_accept( const container_t< ast::ptr<node_t> > & container ) {
     348        typename ast::Pass< core_t >::template resultN<container_t, node_t> ast::Pass< core_t >::call_accept( const container_t< ast::ptr<node_t> > & container ) {
    349349                __pedantic_pass_assert( __visit_children() );
    350350                if( container.empty() ) return {};
  • src/Common/CodeLocation.h

    r12b5e94a r454b4e0  
    2626        CodeLocation() = default;
    2727
     28
    2829        /// Create a new CodeLocation with the given values.
    2930        CodeLocation( const char* filename, int lineno )
     
    3334
    3435        CodeLocation( const CodeLocation& rhs ) = default;
     36        CodeLocation( CodeLocation&& rhs ) = default;
     37        CodeLocation& operator=( const CodeLocation & ) = default;
     38        CodeLocation& operator=( CodeLocation && ) = default;
    3539
    3640        bool isSet () const {
  • src/ControlStruct/MLEMutator.cc

    r12b5e94a r454b4e0  
    6666
    6767        // break labels have to come after the statement they break out of, so mutate a statement, then if they inform us
    68         // through the breakLabel field tha they need a place to jump to on a break statement, add the break label to the
     68        // through the breakLabel field that they need a place to jump to on a break statement, add the break label to the
    6969        // body of statements
    7070        void MultiLevelExitMutator::fixBlock( std::list< Statement * > &kids, bool caseClause ) {
  • src/Makefile.am

    r12b5e94a r454b4e0  
    5959
    6060$(srcdir)/AST/Type.hpp : BasicTypes-gen.cc
    61         ${AM_V_GEN}${CXXCOMPILE} $< -o BasicTypes-gen -Wall -Wextra
     61        ${AM_V_GEN}${CXXCOMPILE} $< -o BasicTypes-gen -Wall -Wextra -Werror=return-type
    6262        @./BasicTypes-gen
    6363        @rm BasicTypes-gen
     
    7171EXTRA_DIST = include/cassert include/optional BasicTypes-gen.cc
    7272
    73 AM_CXXFLAGS = @HOST_FLAGS@ -Wno-deprecated -Wall -Wextra -DDEBUG_ALL -I./Parser -I$(srcdir)/Parser -I$(srcdir)/include -DYY_NO_INPUT -O3 -g -std=c++14 $(TCMALLOCFLAG)
     73AM_CXXFLAGS = @HOST_FLAGS@ -Wno-deprecated -Wall -Wextra -Werror=return-type -DDEBUG_ALL -I./Parser -I$(srcdir)/Parser -I$(srcdir)/include -DYY_NO_INPUT -O3 -g -std=c++14 $(TCMALLOCFLAG)
    7474AM_LDFLAGS  = @HOST_FLAGS@ -Xlinker -export-dynamic
    7575ARFLAGS     = cr
Note: See TracChangeset for help on using the changeset viewer.