mirror of
https://github.com/KLayout/klayout.git
synced 2026-09-03 16:30:20 +02:00
Fixed #39 (Action cannot be reassigned)
This commit is contained in:
Vendored
+9
-1
@@ -3,7 +3,10 @@
|
||||
# extend A
|
||||
class RBA::A
|
||||
|
||||
def initialize
|
||||
alias_method :org_initialize, :initialize
|
||||
|
||||
def initialize(*args)
|
||||
org_initialize(*args)
|
||||
@offset = nil
|
||||
end
|
||||
def s( o )
|
||||
@@ -90,6 +93,11 @@ class Basic_TestClass < TestBase
|
||||
a = RBA::A.new_a(100)
|
||||
assert_equal( RBA::A::a0, ac0 + 1 )
|
||||
|
||||
a = RBA::A.new
|
||||
assert_equal(a.a1, 17)
|
||||
a.assign(RBA::A.new(110))
|
||||
assert_equal(a.a1, 110)
|
||||
|
||||
a = nil
|
||||
GC.start
|
||||
assert_equal( RBA::A::a0, ac0 )
|
||||
|
||||
Reference in New Issue
Block a user