File tree Expand file tree Collapse file tree 3 files changed +3
-11
lines changed Expand file tree Collapse file tree 3 files changed +3
-11
lines changed Original file line number Diff line number Diff line change @@ -41,8 +41,7 @@ def hash
41
41
def eql? ( another )
42
42
Truffle ::Interop ::Java . java_eql? ( @value , @value )
43
43
end
44
-
45
- alias_method :eql? , :==
44
+ alias_method :== , :eql?
46
45
47
46
def equal? ( another )
48
47
nil != @value and JavaObject === another and @value . equals ( another . value )
Original file line number Diff line number Diff line change @@ -367,7 +367,7 @@ def toString
367
367
a_proxy = Module . new do
368
368
define_singleton_method ( :included , included_method )
369
369
class << self
370
- attr_accessor :java_class
370
+ attr_writer :java_class
371
371
def java_class
372
372
JavaUtilities ::wrap_java_value ( @java_class )
373
373
end
Original file line number Diff line number Diff line change @@ -49,6 +49,7 @@ def initialize
49
49
def size
50
50
@variables . size
51
51
end
52
+ alias_method :length , :size
52
53
53
54
private def lookup ( key )
54
55
value = Truffle ::POSIX . getenv ( StringValue ( key ) )
@@ -231,14 +232,6 @@ def empty?
231
232
true
232
233
end
233
234
234
- def length
235
- sz = 0
236
- each { |_k , _v | sz += 1 }
237
- sz
238
- end
239
-
240
- alias_method :size , :length
241
-
242
235
def rehash
243
236
# No need to do anything, our keys are always strings
244
237
end
You can’t perform that action at this time.
0 commit comments