From: "nobu (Nobuyoshi Nakada)" Date: 2022-12-01T09:01:44+00:00 Subject: [ruby-dev:52008] [Ruby master Feature#19163] Data object should be frozen Issue #19163 has been updated by nobu (Nobuyoshi Nakada). https://github.com/ruby/ruby/pull/6843 ---------------------------------------- Feature #19163: Data object should be frozen https://bugs.ruby-lang.org/issues/19163#change-100399 * Author: matz (Yukihiro Matsumoto) * Status: Open * Priority: Normal ---------------------------------------- If we call `initialize` (via `send`), we can rewrite an existing Data object. ```ruby d=Data.define(:a, :b).new(1,2) p d #=> # d.send(:initialize, {a:3,b:4}) p d #=> # ``` Should we freeze the Data object after calling `initialize` for the first time? Matz. -- https://bugs.ruby-lang.org/