doc: fix default field values example (#7847)
parent
9b43b6833b
commit
dce201928a
|
@ -1253,9 +1253,9 @@ button.widget.x = 3
|
||||||
|
|
||||||
```v
|
```v
|
||||||
struct Foo {
|
struct Foo {
|
||||||
n int // n is 0 by default
|
n int // n is 0 by default
|
||||||
s string // s is '' by default
|
s string // s is '' by default
|
||||||
a []int // a is `[]int{}` by default
|
a []int // a is `[]int{}` by default
|
||||||
pos int = -1 // custom default value
|
pos int = -1 // custom default value
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
Loading…
Reference in New Issue