Skip to content

Commit cdbcbd0

Browse files
authored
Merge pull request #577 from tompng/autoload_generic_object
Autoload JSON::GenericObject to avoid require ostruct warning in Ruby 3.4
2 parents 84b7517 + b507f9e commit cdbcbd0

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lib/json/common.rb

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
#frozen_string_literal: false
22
require 'json/version'
3-
require 'json/generic_object'
43

54
module JSON
5+
autoload :GenericObject, 'json/generic_object'
6+
67
NOT_SET = Object.new.freeze
78
private_constant :NOT_SET
89

0 commit comments

Comments
 (0)