Next: , Previous: , Up: Structs   [Contents][Index]


17.5.5 Accessing Fields

Poke uses the usual dot-notation to provide access to struct fields. Examples:

(poke) var s = struct { i = 10, l = 20L }
(poke) s.i
10
(poke) s.l
20L

Writing to fields is achieved by having the field reference in the left side of an assignment statement:

(poke) s.i = 100
(poke) s.l = 200
(poke) s
struct {i=100,l=200L}