How do I _really_ implement opApply?

Steven Schveighoffer schveiguy at gmail.com
Wed Nov 30 01:30:03 UTC 2022


On 11/29/22 7:50 PM, WebFreak001 wrote:

> (note: I don't want to use a template, this way of writing it has the 
> advantage that the compiler checks all different code paths for errors, 
> so the errors aren't delayed until someone actually tries to iterate 
> over my data structure)

1. use the template
2. use a unittest to prove they all compile.

-Steve


More information about the Digitalmars-d-learn mailing list