|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r55161 - in trunk/boost/spirit/home: karma/nonterminal qi/nonterminal
From: hartmut.kaiser_at_[hidden]
Date: 2009-07-30 14:42:07
Author: hkaiser
Date: 2009-07-25 21:07:01 EDT (Sat, 25 Jul 2009)
New Revision: 55161
URL: http://svn.boost.org/trac/boost/changeset/55161
Log:
Spirit: fixed problem in copy constructor of rules
Text files modified:
trunk/boost/spirit/home/karma/nonterminal/rule.hpp | 9 ++-------
trunk/boost/spirit/home/qi/nonterminal/rule.hpp | 9 ++-------
2 files changed, 4 insertions(+), 14 deletions(-)
Modified: trunk/boost/spirit/home/karma/nonterminal/rule.hpp
==============================================================================
--- trunk/boost/spirit/home/karma/nonterminal/rule.hpp (original)
+++ trunk/boost/spirit/home/karma/nonterminal/rule.hpp 2009-07-25 21:07:01 EDT (Sat, 25 Jul 2009)
@@ -177,18 +177,13 @@
bool(output_iterator&, context_type&, delimiter_type const&)>
function_type;
- rule(std::string const& name_ = "unnamed-rule")
+ explicit rule(std::string const& name_ = "unnamed-rule")
: base_type(terminal::make(alias()))
, name_(name_)
{
}
- rule(rule const& rhs)
- : base_type(terminal::make(alias()))
- , name_(rhs.name_)
- , f(rhs.f)
- {
- }
+ // the default copy constructor does the right thing
rule& operator=(rule const& rhs)
{
Modified: trunk/boost/spirit/home/qi/nonterminal/rule.hpp
==============================================================================
--- trunk/boost/spirit/home/qi/nonterminal/rule.hpp (original)
+++ trunk/boost/spirit/home/qi/nonterminal/rule.hpp 2009-07-25 21:07:01 EDT (Sat, 25 Jul 2009)
@@ -170,18 +170,13 @@
)>
function_type;
- rule(std::string const& name_ = "unnamed-rule")
+ explicit rule(std::string const& name_ = "unnamed-rule")
: base_type(terminal::make(alias()))
, name_(name_)
{
}
- rule(rule const& rhs)
- : base_type(terminal::make(alias()))
- , name_(rhs.name_)
- , f(rhs.f)
- {
- }
+ // the default copy constructor does the right thing
rule& operator=(rule const& rhs)
{
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