homura-runtime 0.3.28 → 0.3.29

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6157c91e804deebc3400c37f1854696e271c36f16b5f92fd6a201a182c3fe377
4
- data.tar.gz: a99cdf2547fa59a85cb8cc3cbbe28c83626d2daec163634cf86d1675a704f4f4
3
+ metadata.gz: 523d660c486440b910fded423765e28c7a00d0196ff30f08f41c81b76eb897bd
4
+ data.tar.gz: 4e4adc4159f071b90329058c1f0a7638a2a6c52d29d4b344ff7c3d03633adc5d
5
5
  SHA512:
6
- metadata.gz: 5d3c5eeaf352d50b0c14f3bfc5dd0425486478325136c5c1d7b75c794cdb5d9eff476e2efd55bfbda1afa88c3f7895319dc7765b26b92d491bd40bd182414ca4
7
- data.tar.gz: b943e7d0f0bb0a489f3a0bb8430deac4a04ecc83ca547b4cd0a9fbae2a797c040913331f270fcfc7d8f09cfdafe5b4baff2f2dbf189d4eefd359019bb18e24f0
6
+ metadata.gz: 37a0e501e9ef564074cc70a0b0284b6ed0046c482343353038148d8daabd1300f9a044c62e12a4451bf65caf4f8d9d8933b0f987c32a20bedf62886d5a423940
7
+ data.tar.gz: 47b3d1af25629338706e4ca0481cc0dc98992eae4a96bb981fac036bfce569332c6c283d9e31c35ce97bb45d48c712a7c9640b66cdfdd49eefe56ac9b7466d03
data/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.3.29 (2026-06-25)
4
+
5
+ - Provide an Opal-safe `Literal::Types::JSONDataType` shim instead of loading
6
+ the upstream frozen singleton implementation, avoiding Opal constant-cache
7
+ writes against frozen objects during Worker boot.
8
+
3
9
  ## 0.3.28 (2026-06-25)
4
10
 
5
11
  - Bootstrap the `Literal::Types` namespace, load Literal's type classes, then
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module HomuraRuntime
4
- VERSION = "0.3.28"
4
+ VERSION = "0.3.29"
5
5
  end
@@ -20,7 +20,6 @@ require "literal/types/frozen_type"
20
20
  require "literal/types/hash_type"
21
21
  require "literal/types/interface_type"
22
22
  require "literal/types/intersection_type"
23
- require "literal/types/json_data_type"
24
23
  require "literal/types/kind_type"
25
24
  require "literal/types/map_type"
26
25
  require "literal/types/never_type"
@@ -35,6 +34,28 @@ require "literal/types/truthy_type"
35
34
  require "literal/types/tuple_type"
36
35
  require "literal/types/union_type"
37
36
  require "literal/types/void_type"
37
+
38
+ class Literal::Types::JSONDataType
39
+ Instance = new
40
+
41
+ include Literal::Type
42
+
43
+ def inspect = "_JSONData"
44
+
45
+ def ===(value)
46
+ case value
47
+ when String, Integer, Float, true, false, nil
48
+ true
49
+ when Hash
50
+ value.all? { |key, item| String === key && self === item }
51
+ when Array
52
+ value.all?(self)
53
+ else
54
+ false
55
+ end
56
+ end
57
+ end
58
+
38
59
  require "literal/types"
39
60
 
40
61
  module Literal
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: homura-runtime
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.28
4
+ version: 0.3.29
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kazuhiro Homma