Re: [go-nuts] Union types mindset

2017-11-21 Thread 'Paulo Matos' via golang-nuts
ces (this is a common pattern in Go, to make sure any change to a > concrete type to make it /not/ implement a particular interface result > in a compile-time error). > > > > > > *Josh Humphries* > jh...@bluegosling.com <mailto:jh...@bluegosling.com>

[go-nuts] Union types mindset

2017-11-20 Thread &#x27;Paulo Matos&#x27; via golang-nuts
Hello, I am trying to write a simple assembler file parser. I just started developing in Go so I have the wrong mindset. I am keen to understand the best way to write something like this in Go. An assembler file at first glance is a list of instructions, directives and labels. I know there are