diff options
-rw-r--r-- | build2/variable | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/build2/variable b/build2/variable index abff1d5..8fc1fb9 100644 --- a/build2/variable +++ b/build2/variable @@ -221,7 +221,7 @@ namespace build2 // Fast, unchecked cast of data_ to T. // template<typename T> T& as () & {return reinterpret_cast<T&> (data_);} - template<typename T> T&& as () && {return reinterpret_cast<T&&> (data_);} + template<typename T> T&& as () && {return move (as<T> ());} template<typename T> const T& as () const& { return reinterpret_cast<const T&> (data_);} |