Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r73493 - sandbox/tools/profile_templates2/src
From: dsaritz_at_[hidden]
Date: 2011-08-02 09:16:50


Author: psiha
Date: 2011-08-02 09:16:49 EDT (Tue, 02 Aug 2011)
New Revision: 73493
URL: http://svn.boost.org/trac/boost/changeset/73493

Log:
Fixed the static regex expressions to create proper captures.
Added missing sregex::compile() calls for GCC related regex objects.
Text files modified:
   sandbox/tools/profile_templates2/src/postprocess.cpp | 24 ++++++++++++------------
   1 files changed, 12 insertions(+), 12 deletions(-)

Modified: sandbox/tools/profile_templates2/src/postprocess.cpp
==============================================================================
--- sandbox/tools/profile_templates2/src/postprocess.cpp (original)
+++ sandbox/tools/profile_templates2/src/postprocess.cpp 2011-08-02 09:16:49 EDT (Tue, 02 Aug 2011)
@@ -46,26 +46,26 @@
 
         #pragma warning(disable:4512)
 
- sregex const enter_message ( (*~_n) >> " : warning C4150: deletion of pointer to incomplete type 'template_profiler::incomplete_enter'; no destructor called" );
- sregex const exit_message ( (*~_n) >> " : warning C4150: deletion of pointer to incomplete type 'template_profiler::incomplete_exit'; no destructor called" );
- sregex const call_graph_line ( " " >> (*~_n) >> '(' >> +_d >> ')' >> " : see reference to " >> (*~_n) );
- sregex const split_file_and_line( (*~_n) >> '(' >> +_d >> ')' );
+ sregex const enter_message ( (s1= *_) >> " : warning C4150: deletion of pointer to incomplete type 'template_profiler::incomplete_enter'; no destructor called" );
+ sregex const exit_message ( (s1= *_) >> " : warning C4150: deletion of pointer to incomplete type 'template_profiler::incomplete_exit'; no destructor called" );
+ sregex const call_graph_line ( " " >> (s1= *_) >> '(' >> ( s2= +_d ) >> ')' >> " : see reference to " >> *_ );
+ sregex const split_file_and_line( (s1= *_) >> '(' >> ( s2= +_d ) >> ')' );
 
     #elif defined(__GNUC__)
 
         #if (__GNUC__ < 4) || (__GNUC_MINOR__ < 3)
 
- sregex const enter_message ("(.*): warning: division by zero in .template_profiler::enter_value / 0.");
- sregex const exit_message ("(.*): warning: division by zero in .template_profiler::exit_value / 0.");
- sregex const call_graph_line ("(.*):(\\d+): instantiated from .*");
- sregex const split_file_and_line("(.*):(\\d+)");
+ sregex const enter_message (sregex::compile( "(.*): warning: division by zero in .template_profiler::enter_value / 0."));
+ sregex const exit_message (sregex::compile( "(.*): warning: division by zero in .template_profiler::exit_value / 0." ));
+ sregex const call_graph_line (sregex::compile( "(.*):(\\d+): instantiated from .*" ));
+ sregex const split_file_and_line(sregex::compile( "(.*):(\\d+)" ));
 
         #else
 
- sregex const enter_message ("(.*): warning: .+int template_profiler::enter\\(int\\).*");
- sregex const exit_message ("(.*): warning: .+int template_profiler::exit\\(int\\).*");
- sregex const call_graph_line ("(.*):(\\d+): instantiated from .*");
- sregex const split_file_and_line("(.*):(\\d+)");
+ sregex const enter_message (sregex::compile( "(.*): warning: .+int template_profiler::enter\\(int\\).*"));
+ sregex const exit_message (sregex::compile( "(.*): warning: .+int template_profiler::exit\\(int\\).*" ));
+ sregex const call_graph_line (sregex::compile( "(.*):(\\d+): instantiated from .*" ));
+ sregex const split_file_and_line(sregex::compile( "(.*):(\\d+)" ));
 
         #endif
 


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk