(emulating) weak typing and some other things

H. S. Teoh hsteoh at quickfur.ath.cx
Fri Dec 20 09:40:47 PST 2013


On Fri, Dec 20, 2013 at 06:30:53PM +0100, seany wrote:
> I am sorry, perhaps the question could be answered with already
> available information, but I did not manage to figure it completely
> 
> I realize that D is a strongly typed language. But in certain
> scenarios i may want to use a weak typing, especially when handling
> structs which are very close to each other in content, but not equal,
> it would be nice to use to redefine the type while preserving the
> name.
[...]

See std.typecons.Variant.


T

-- 
The volume of a pizza of thickness a and radius z can be described by the following formula: pi zz a. -- Wouter Verhelst


More information about the Digitalmars-d-learn mailing list