[DOC] Fix a magic comment in the section for experimental_copy

This commit is contained in:
Ivanov-Anton 2023-07-18 13:23:27 +03:00 committed by GitHub
parent 56c8dab468
commit b89b7d8fdc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
Notes: git 2023-07-18 10:23:46 +00:00
Merged: https://github.com/ruby/ruby/pull/8087

Merged-By: nobu <nobu@ruby-lang.org>

View File

@ -196,7 +196,7 @@ The method Module#const_set is not affected.
In this mode, all values assigned to constants are deeply copied and In this mode, all values assigned to constants are deeply copied and
made shareable. It is safer mode than +experimental_everything+. made shareable. It is safer mode than +experimental_everything+.
# shareable_constant_value: experimental_everything # shareable_constant_value: experimental_copy
var = [{foo: []}] var = [{foo: []}]
var.frozen? # => false (assignment was made to local variable) var.frozen? # => false (assignment was made to local variable)
X = var # => calls `Ractor.make_shareable(var, copy: true)` X = var # => calls `Ractor.make_shareable(var, copy: true)`