correct way to create boiler plate code

Trass3r un at known.com
Mon May 16 12:20:48 PDT 2011


> string[] funcs = ["tan"];

> calling mixin a compile time has the following error...
>
> Error	1	Error: variable func cannot be read at compile time
> 	C:\D\SVNProjects\trunk\xcellD\xcell1\trig.d	22

That's because funcs is mutable.
Try to make it immutable or enum.


More information about the Digitalmars-d-learn mailing list