3 ms·
Which IDE do you use? Mine would flag this as an error pretty quickly.
by latchkey 3y ago
Which IDE do you use? Mine would flag this as an error pretty quickly.
- jjallen 3y agoGoland. How would an IDE know that you intended a struct field to be public or not?
- latchkey 3y agoAny non-private usage of a private struct is a compile error. If you're using goland, it would report this as an error as it is effectively compiling your code as you write it. Also, autocomplete wouldn't work when you tried to use the private struct.