Changeset c94b1f0


Ignore:
Timestamp:
Mar 23, 2023, 1:50:38 PM (2 months ago)
Author:
Andrew Beach <ajbeach@…>
Branches:
ADT, master
Children:
056bee8
Parents:
d800676
Message:

Removed unused (debug only?) code. If you want to change how GenStructMemberCalls? handles errors you may just need to write a local helper.

Location:
src
Files:
1 deleted
4 edited

Legend:

Unmodified
Added
Removed
  • src/Common/module.mk

    rd800676 rc94b1f0  
    2020        Common/CodeLocationTools.hpp \
    2121        Common/CodeLocationTools.cpp \
    22         Common/Debug.h \
    2322        Common/DeclStats.hpp \
    2423        Common/DeclStats.cpp \
  • src/Common/utility.h

    rd800676 rc94b1f0  
    190190}
    191191
    192 template< typename... Params >
    193 void warn( const Params & ... params ) {
    194         std::cerr << "Warning: ";
    195         toString_single( std::cerr, params... );
    196         std::cerr << std::endl;
    197 }
    198 
    199192// determines if pref is a prefix of str
    200193static inline bool isPrefix( const std::string & str, const std::string & pref, unsigned int start = 0 ) {
  • src/InitTweak/FixInit.cc

    rd800676 rc94b1f0  
    12331233                }
    12341234
    1235                 template< typename Visitor, typename... Params >
    1236                 void error( Visitor & v, CodeLocation loc, const Params &... params ) {
    1237                         SemanticErrorException err( loc, toString( params... ) );
    1238                         v.errors.append( err );
    1239                 }
    1240 
    12411235                template< typename... Params >
    12421236                void GenStructMemberCalls::emit( CodeLocation loc, const Params &... params ) {
    1243                         // toggle warnings vs. errors here.
    1244                         // warn( params... );
    1245                         error( *this, loc, params... );
     1237                        SemanticErrorException err( loc, toString( params... ) );
     1238                        errors.append( err );
    12461239                }
    12471240
  • src/InitTweak/FixInitNew.cpp

    rd800676 rc94b1f0  
    13031303        }
    13041304
    1305         template< typename Visitor, typename... Params >
    1306         void error( Visitor & v, CodeLocation loc, const Params &... params ) {
    1307                 SemanticErrorException err( loc, toString( params... ) );
    1308                 v.errors.append( err );
    1309         }
    1310 
    13111305        template< typename... Params >
    13121306        void GenStructMemberCalls::emit( CodeLocation loc, const Params &... params ) {
    1313                 // toggle warnings vs. errors here.
    1314                 // warn( params... );
    1315                 error( *this, loc, params... );
     1307                SemanticErrorException err( loc, toString( params... ) );
     1308                errors.append( err );
    13161309        }
    13171310
Note: See TracChangeset for help on using the changeset viewer.