Object object := method( result := Object clone call message arguments foreach(i, arg, if (arg name == "updateSlot" or arg name == "setSlot" or arg name == "setSlotWithType", result newSlot(arg argAt(0) cachedResult, call sender doMessage(arg argAt(1), call sender)) , result newSlot(arg name) ) ) result ) Object curlyBrackets := Object getSlot("object") # For example... #Io> Object curlyBrackets := Object getSlot("object") #Io> writeln({a = 1, b = 2}) # # Object_0x84aaab8: # a = 1 # b = 2 # setA = method(...) # setB = method(...) #Io> writeln(object(a, b, c=3, d=4)) # # Object_0x8510b58: # a = nil # b = nil # c = 3 # d = 4 # setA = method(...) # setB = method(...) # setC = method(...) # setD = method(...) #Io> Foo := object(bar, baz) do ( # bongle := method(x, # writeln(x, " ", bar, " ", baz) # ) # ) #Io> writeln(Foo) # # Foo_0x8519c88: # bar = nil # baz = nil # bongle = method(x, ...) # setBar = method(...) # setBaz = method(...) # type = "Foo"