mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
compiler: force custom struct .str() methods to be defined public
This commit is contained in:

committed by
Alexander Medvednikov

parent
f286387647
commit
3486118ab7
@ -341,11 +341,11 @@ mut:
|
||||
b []Test2
|
||||
}
|
||||
|
||||
fn (t Test2) str() string {
|
||||
pub fn (t Test2) str() string {
|
||||
return '{$t.one $t.two}'
|
||||
}
|
||||
|
||||
fn (t Test) str() string {
|
||||
pub fn (t Test) str() string {
|
||||
return '{$t.a $t.b}'
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user