Files
wren/test/language/assignment/compound_subscript_list.wren
underscorediscovery 903f2eae07 add <<= and >>=
2019-10-01 00:51:22 -07:00

21 lines
324 B
Plaintext

var list = [1,2,3,4]
list[0] += 10
System.print(list[0]) // expect: 11
list[1] -= 3
System.print(list[1]) // expect: -1
list[2] *= 9
System.print(list[2]) // expect: 27
list[3] /= 2
System.print(list[3]) // expect: 2
list[0] <<= 2
System.print(list[0]) // expect: 44
list[2] >>= 1
System.print(list[2]) // expect: 13