digitalmars.D.learn - typedef deprecated - now what ?
- Stephan <spam extrawurst.org> Dec 30 2011
- Caligo <iteronvexor gmail.com> Dec 30 2011
- Trass3r <un known.com> Dec 30 2011
- Stephan <spam extrawurst.org> Dec 30 2011
- Torarin <torarind gmail.com> Dec 30 2011
- Jonathan M Davis <jmdavisProg gmx.com> Dec 30 2011
- Stewart Gordon <smjg_1998 yahoo.com> Dec 31 2011
- Trass3r <un known.com> Dec 31 2011
- Stewart Gordon <smjg_1998 yahoo.com> Jan 01 2012
is there a template or something in phobos to get the same typesafe behaviour of good old typedef ? S.
Dec 30 2011
--20cf307d06ce8096d704b54cf096 Content-Type: text/plain; charset=ISO-8859-1 On Fri, Dec 30, 2011 at 4:35 AM, Stephan <spam extrawurst.org> wrote:is there a template or something in phobos to get the same typesafe behaviour of good old typedef ? S.
Get over it, move on, and hope they fix the thousands of bugs left in DMD. P.S. use `alias`. --20cf307d06ce8096d704b54cf096 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable <br><br><div class=3D"gmail_quote">On Fri, Dec 30, 2011 at 4:35 AM, Stephan= <span dir=3D"ltr"><<a href=3D"mailto:spam extrawurst.org">spam extrawur= st.org</a>></span> wrote:<br><blockquote class=3D"gmail_quote" style=3D"= margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"> is there a template or something in phobos to get the same typesafe behavio= ur of good old typedef ?<span class=3D"HOEnZb"><font color=3D"#888888"><br> <br> S.<br> </font></span></blockquote></div><br><div>Get over it, move on, and hope th= ey fix the=A0thousands=A0of bugs left in DMD.</div><div><br></div><div>P.S.= </div><div>use `alias`. =A0</div> --20cf307d06ce8096d704b54cf096--
Dec 30 2011
is there a template or something in phobos to get the same typesafe behaviour of good old typedef ?
I've brought this up several times. People just don't give a shit. http://d.puremagic.com/issues/show_bug.cgi?id=5467
Dec 30 2011
On 30.12.2011 12:09, Trass3r wrote:is there a template or something in phobos to get the same typesafe behaviour of good old typedef ?
I've brought this up several times. People just don't give a shit. http://d.puremagic.com/issues/show_bug.cgi?id=5467
thats too bad. pull request looks good. i voted for the ticket, but i guess that no one gives shit about that either :(
Dec 30 2011
2011/12/30 Stephan <spam extrawurst.org>:On 30.12.2011 12:09, Trass3r wrote:is there a template or something in phobos to get the same typesafe behaviour of good old typedef ?
I've brought this up several times. People just don't give a shit. http://d.puremagic.com/issues/show_bug.cgi?id=5467
thats too bad. pull request looks good. i voted for the ticket, but i guess that no one gives shit about that either :(
Sure they give a shit. :-) I think Andrei is currently looking into ProxyOf for a new reference-counting type constructor. Torarin
Dec 30 2011
On Friday, December 30, 2011 11:35:28 Stephan wrote:is there a template or something in phobos to get the same typesafe behaviour of good old typedef ?
There's a pull request being reviewed but nothing in Phobos yet. https://github.com/D-Programming-Language/phobos/pull/300 - Jonathan M Davis
Dec 30 2011
On 30/12/2011 10:35, Stephan wrote:is there a template or something in phobos to get the same typesafe behaviour of good old typedef ?
Could someone please provide a link to the thread with the reasons for deprecating typedef? There are too many threads with the words "typedef" and "deprecate" in them for me to find it easily. Stewart.
Dec 31 2011
Basically it was deprecated because it's poorly defined and implemented. There are several types of typedefs that need to be available: parallel, opaque, supertype and subtype. See http://d.puremagic.com/issues/show_bug.cgi?id=5467
Dec 31 2011
On 31/12/2011 13:34, Trass3r wrote:Basically it was deprecated because it's poorly defined and implemented.
Would you care to elaborate? Moreover, if that's the only reason then why not improve it rather than getting rid of it?There are several types of typedefs that need to be available: parallel, opaque, supertype and subtype. See http://d.puremagic.com/issues/show_bug.cgi?id=5467
I see. So the built-in typedef is closest in semantics to subtype, but leaves bits to be desired. Stewart.
Jan 01 2012









Caligo <iteronvexor gmail.com> 