mirror of
https://github.com/ChaiScript/ChaiScript.git
synced 2026-05-01 03:19:28 +08:00
Cast_Helper_Inner<T&&> unconditionally called std::move() on the underlying object, even when the Boxed_Value held an lvalue reference (is_ref() == true). This caused T&& overloads to win over const T& overloads for objects returned by reference, silently moving from and destroying persistent objects. The fix rejects the T&& cast for reference Boxed_Values, allowing dispatch to fall through to the correct const T& overload. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| dispatchkit | ||
| language | ||
| utility | ||
| chaiscript_basic.hpp | ||
| chaiscript_defines.hpp | ||
| chaiscript_stdlib.hpp | ||
| chaiscript_threading.hpp | ||
| chaiscript.hpp | ||