xo-inteerpreter2: rework VsmResult to use pointer
Preefer to maintain ref to VSM.result_, since gc will preserve it.
This commit is contained in:
parent
822fef7de3
commit
a067d0f7b2
3 changed files with 27 additions and 8 deletions
|
|
@ -103,6 +103,8 @@ namespace xo {
|
|||
{
|
||||
scope log(XO_DEBUG(debug_flag));
|
||||
|
||||
// WARNING: res.value() is unstable - gc may move it
|
||||
|
||||
VsmResultExt res = vsm_->read_eval_print(input_span, eof_flag);
|
||||
|
||||
REQUIRE(res.is_value());
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue