www.digitalmars.com         C & C++   DMDScript  

D - Example: wc

Hi,

I had to make a change to "wc.d" from http://www.digital-mars.com/d/wc.html
to make it compile.

This line:
    input = File.read(args[i]);
has to read:
    input = cast(char[])file.read(args[i]);

It seems that two changes has happened since the example was written:
1. The module name has become case sensitive.
2. We need to cast byte[] to char[].

Regards,
Martin M. Pedersen
May 21 2003