Topic: templates
Author: "Walter" <walternospamm@digitalmars.nospaam.com>
Date: 13 Jan 03 09:04:44 GMT Raw View
"stephan beal" <stephan@wanderinghorse.net> wrote in message
news:avmb2g$qbf$1@ork.noris.net...
> Walter wrote:
> > The D Programming Language, www.digitalmars.com/d/, has sophisticated
> > templates as well, including things like partial ordering and partial
> > specialization, all with a much easier to use syntax than C
> ]
> Java will also get templates soon:
> http://developer.java.sun.com/developer/technicalArticles/releases/gener
> ics/
>
> But without the ability to typedef i would imagine that they will be
> effectively unusuable for nested template definitions (too unreadable
> and
> unmaintainable, IMO). For example, nobody is going to want to write (or
> read) this all the time:
>
> Foo<Bar<FooBar>> myobj;
>
> when they could instead have this:
> FooBarType myobj;
D has both C++ style weak typedefs (aka type aliases) and strong typedefs.
[ Send an empty e-mail to c++-help@netlab.cs.rpi.edu for info ]
[ about comp.lang.c++.moderated. First time posters: do this! ]
[ comp.std.c++ is moderated. To submit articles, try just posting with ]
[ your news-reader. If that fails, use mailto:std-c++@ncar.ucar.edu ]
[ --- Please see the FAQ before posting. --- ]