A type-safe collection preserves its declared element type without unchecked runtime conversions. Code generation creates type-specific collections, such as queues, while avoiding type assertions, runtime safety problems, and their performance cost. section 13.3
Generating a MyInt queue
A //go:generate ./queue MyInt directive invokes the generator. Running go generate creates myint_queue.go; the program then constructs NewMyIntQueue, inserts three MyInt values, and removes 1 first.
