Issue #10140 has been reported by Tomoyuki Chikanaga.

----------------------------------------
Backport #10140: Backport r47191 (don't pass a non-VALUE argument to RB_OBJ_WRITE)
https://bugs.ruby-lang.org/issues/10140

* Author: Tomoyuki Chikanaga
* Status: Assigned
* Priority: Normal
* Assignee: Tomoyuki Chikanaga
----------------------------------------
In commit message:

    Should not insert write barrier from
    non-RVALUE data (to non-RVALUE data, of course).
    Ruby 2.1 also has a same problem.



-- 
https://bugs.ruby-lang.org/