www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - documentation error concerning cast

on page http://www.digitalmars.com/d/type.html

------------------------------------------------------------------------
Implicit Conversions
D has a lot of types, both built in and derived. It would be tedious to 
require casts for every type conversion, so implicit conversions step in 
to handle the obvious ones automatically.

A typedef can be implicitly converted to its underlying type, but going 
the other way requires an explicit conversion. For example:

	typedef int myint;
	int i;
	myint m;
	i = m;		// OK
	m = i;		// error
	m = (myint)i;	// OK
------------------------------------------------------------------------

===> last line, should become
m = cast(myint)i;
	
bye,
roel
May 19 2004