update repls tests
parent
65426821c4
commit
3b929cdd03
|
@ -32,47 +32,47 @@
|
||||||
/*(17)*/ e.v << 1 // Error (e immutable)
|
/*(17)*/ e.v << 1 // Error (e immutable)
|
||||||
|
|
||||||
===output===
|
===output===
|
||||||
.vrepl_temp.v:27:14: cannot modify immutable field `len` (type `string`)
|
cannot modify immutable field `len` (type `string`)
|
||||||
declare the field with `mut:`
|
declare the field with `mut:`
|
||||||
struct string {
|
struct string {
|
||||||
mut:
|
mut:
|
||||||
len int
|
len int
|
||||||
}
|
}
|
||||||
.vrepl_temp.v:30:14: cannot modify immutable field `a` (type `B`)
|
cannot modify immutable field `a` (type `B`)
|
||||||
declare the field with `mut:`
|
declare the field with `mut:`
|
||||||
struct B {
|
struct B {
|
||||||
mut:
|
mut:
|
||||||
a A
|
a A
|
||||||
}
|
}
|
||||||
.vrepl_temp.v:29:12: cannot modify immutable field `a` (type `B`)
|
cannot modify immutable field `a` (type `B`)
|
||||||
declare the field with `mut:`
|
declare the field with `mut:`
|
||||||
struct B {
|
struct B {
|
||||||
mut:
|
mut:
|
||||||
a A
|
a A
|
||||||
}
|
}
|
||||||
.vrepl_temp.v:41:14: cannot modify immutable field `a` (type `B`)
|
cannot modify immutable field `a` (type `B`)
|
||||||
declare the field with `mut:`
|
declare the field with `mut:`
|
||||||
struct B {
|
struct B {
|
||||||
mut:
|
mut:
|
||||||
a A
|
a A
|
||||||
}
|
}
|
||||||
.vrepl_temp.v:42:16: cannot modify immutable field `a` (type `B`)
|
cannot modify immutable field `a` (type `B`)
|
||||||
declare the field with `mut:`
|
declare the field with `mut:`
|
||||||
struct B {
|
struct B {
|
||||||
mut:
|
mut:
|
||||||
a A
|
a A
|
||||||
}
|
}
|
||||||
.vrepl_temp.v:44:15: `c2` is immutable
|
`c2` is immutable
|
||||||
.vrepl_temp.v:53:12: cannot modify immutable field `e` (type `F`)
|
cannot modify immutable field `e` (type `F`)
|
||||||
declare the field with `mut:`
|
declare the field with `mut:`
|
||||||
struct F {
|
struct F {
|
||||||
mut:
|
mut:
|
||||||
e []E
|
e []E
|
||||||
}
|
}
|
||||||
.vrepl_temp.v:54:17: cannot modify immutable field `e` (type `F`)
|
cannot modify immutable field `e` (type `F`)
|
||||||
declare the field with `mut:`
|
declare the field with `mut:`
|
||||||
struct F {
|
struct F {
|
||||||
mut:
|
mut:
|
||||||
e []E
|
e []E
|
||||||
}
|
}
|
||||||
.vrepl_temp.v:57:17: `e` is immutable (can't <<)
|
`e` is immutable (can't <<)
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
a
|
a
|
||||||
33
|
33
|
||||||
===output===
|
===output===
|
||||||
.vrepl_temp.v:3:9: undefined: `a`
|
undefined: `a`
|
||||||
33
|
33
|
||||||
|
|
|
@ -9,19 +9,19 @@ ints.len = 0 // Error (field len immutable)
|
||||||
|
|
||||||
println('BYE')
|
println('BYE')
|
||||||
===output===
|
===output===
|
||||||
.vrepl_temp.v:3:5: cannot modify immutable field `len` (type `string`)
|
cannot modify immutable field `len` (type `string`)
|
||||||
declare the field with `mut:`
|
declare the field with `mut:`
|
||||||
struct string {
|
struct string {
|
||||||
mut:
|
mut:
|
||||||
len int
|
len int
|
||||||
}
|
}
|
||||||
.vrepl_temp.v:4:5: cannot modify immutable field `len` (type `array`)
|
cannot modify immutable field `len` (type `array`)
|
||||||
declare the field with `mut:`
|
declare the field with `mut:`
|
||||||
struct array {
|
struct array {
|
||||||
mut:
|
mut:
|
||||||
len int
|
len int
|
||||||
}
|
}
|
||||||
.vrepl_temp.v:5:8: cannot modify immutable field `len` (type `array`)
|
cannot modify immutable field `len` (type `array`)
|
||||||
declare the field with `mut:`
|
declare the field with `mut:`
|
||||||
struct array {
|
struct array {
|
||||||
mut:
|
mut:
|
||||||
|
|
Loading…
Reference in New Issue