squared 0.4.30 → 0.5.0

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.
@@ -1,32 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module Squared
4
- module Workspace
5
- module Support
6
- class << self
7
- def hashobj
8
- Hash.new { |data, key| data[key] = {} }
9
- end
10
-
11
- def hashlist
12
- Hash.new { |data, key| data[key] = [] }
13
- end
14
-
15
- def hashdup(data, pass: {})
16
- ret = {}
17
- data.each do |key, val|
18
- ret[key] = case val
19
- when Hash
20
- pass[val] ||= hashdup(val, pass: pass)
21
- when Proc, Method
22
- val
23
- else
24
- val.dup
25
- end
26
- end
27
- ret
28
- end
29
- end
30
- end
31
- end
32
- end