diff options
| author | MenTaLguY <mental@rydia.net> | 2007-03-05 06:07:39 +0000 |
|---|---|---|
| committer | mental <mental@users.sourceforge.net> | 2007-03-05 06:07:39 +0000 |
| commit | e675b42e6fb4e1d816fbd422ca11530746f18dee (patch) | |
| tree | e2e61b2e1bf50f9f2903b76249c274c86a4b59c2 /src/libnr | |
| parent | Separate NRRect and NR::Rect a bit further; the goal is to get to the point w... (diff) | |
| download | inkscape-e675b42e6fb4e1d816fbd422ca11530746f18dee.tar.gz inkscape-e675b42e6fb4e1d816fbd422ca11530746f18dee.zip | |
fix NR::Maybe typos
(bzr r2552)
Diffstat (limited to 'src/libnr')
| -rw-r--r-- | src/libnr/nr-maybe.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libnr/nr-maybe.h b/src/libnr/nr-maybe.h index 679cd9d57..6749dfc01 100644 --- a/src/libnr/nr-maybe.h +++ b/src/libnr/nr-maybe.h @@ -30,7 +30,7 @@ class Maybe { public: Maybe(Nothing) : _is_nothing(true) {} Maybe(T const &t) : _t(t), _is_nothing(false) {} - Maybe(Maybe const &m) : _t(*m._t), _is_nothing(m._is_nothing) {} + Maybe(Maybe const &m) : _t(m._t), _is_nothing(m._is_nothing) {} template <typename T2> Maybe(Maybe<T2> const &m) : _is_nothing(!m) @@ -163,7 +163,7 @@ public: Maybe(Maybe const &m) : _ref(m._ref) {} template <typename T2> Maybe(Maybe<T2> const &m) - : _ref( m ? *m : NULL ) {} + : _ref( m ? &*m : NULL ) {} template <typename T2> Maybe(T2 &t) : _ref(&t) {} operator bool() const { return _ref; } @@ -195,7 +195,7 @@ public: template <typename T2> bool operator!=(NR::Maybe<T2> const &other) const { if ( !_ref || !other ) { - return _ref || _other; + return _ref || other; } else { return *_ref != *other; } |
