Templates and stringof...

David Nadlinger see at klickverbot.at
Fri Aug 3 15:41:27 PDT 2012


On Friday, 3 August 2012 at 21:33:35 UTC, Era Scarecrow wrote:
>  Because a string doesn't hold it's type information for size 
> checking.
>
>  int = 4 bytes or 32 bits
>  string = ????

Just emit the check into the code you generate.

>  It also checks for unsuitable types like structs and floats; 
> can't do that with strings.

Just emit the check into the code you generate.

David


More information about the Digitalmars-d-learn mailing list