From: Beman Dawes (beman_at_[hidden])
Date: 2000-07-12 10:05:32
Using the technique described in
have taken a first cut at building a smart pointer feature diagram.
For now, the feature diagram is in pure text form (see below) for
convenient email discussion. As it matures, it would be converted to HTML
so that the feature names can link to descriptions. See
for what one of the descriptions might look like.
Long term readers of this list should (I hope) recognize most of the
features based on the names alone. Description pages would follow
The motivation of this post is both to start a discussion of feature
modeling and generative programming techniques in general, and to actually
make some progress on smart pointers in particular.
----- Smart Pointer Feature Diagram ----
Draft of 12 July 2000
smart-pointer ( ownership
operations // dereference, get, etc.
[multi-ptr-aquisition-safe] // shared-in-ptr
ownership ( tightly-held // scoped_ptr
| transferable // auto_ptr
| shared // shared_ptr, linked_ptr, etc.
| weak // ??? weak_ptr
| copyable // copy_ptr
release ( non-array
T-visability ( complete
operations ( with-conversion-to-T-star
// Choosing a size forces some of the other features.
// Likewise, Choosing some of the other features forces size.
// This may be an example of an "aspect"; I need to read C&E more
// to be sure
size ( one-ptr // scoped_ptr, auto_ptr, copy_ptr
| two_ptr // shared_ptr
| three_ptr // linked_ptr
shared ( invasive-reference-count // shared_in_ptr
| separate-reference-count // shared_ptr
| linked-list // linked_ptr
( direct // shared_ptr
| indirect // like shared_ptr but ptr stored with count
---- end ----
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk