Opened 12 years ago

Closed 11 years ago

#5167 closed Bugs (wontfix)

Allow proto::extends default ctor to leave the proto_expr_ member uninitialized

Reported by: antoine.de-maricourt@… Owned by: Eric Niebler
Milestone: To Be Determined Component: proto
Version: Boost 1.46.0 Severity: Optimization
Keywords: proto, extends, default constructor Cc:

Description

Proposal:

turn default ctor for proto::extends in proto/extends.hpp from:

extends(): proto_expr_(){}

to:

 extends() { }

Rational: It is up to the derived class to decide if expr can be left in undefined state (and to control it), and not to the extends base class.

Change History (1)

comment:1 by Eric Niebler, 11 years ago

Resolution: wontfix
Status: newclosed

After considering this, I've decided that there isn't sufficient justification for extends to leave its member uninitialized. I recommend BOOST_PROTO_EXTENDS for when you don't want to initialize the member.

Note: See TracTickets for help on using tickets.