Re: Getting All Instantiations of a Template

2009-10-25 Thread Walter Bright
dsimcha wrote: Is there currently a way in D2 to get the parameters of all instantiations of a template in a given scope? Templates are instantiated lazily, meaning it doesn't make much sense to figure this out at compile time.

Re: Private enum members + Descent

2009-10-25 Thread Yigal Chripun
On 25/10/2009 01:22, Michel Fortin wrote: On 2009-10-24 18:45:10 -0400, Justin Johansson n...@spam.com said: Let me try again. You have a set of N things which are represented by an enum definition. There is some subset of this set containing M things (so M N) which represents the things

Re: [OT] What should be in a programming language?

2009-10-25 Thread Yigal Chripun
On 25/10/2009 06:26, Jason House wrote: My web search and some PDF's didn't turn up a handy example. You can do things in scala like define your own foreach loop. If foreach had the form form foreach(x){y} then x would be one set of arguments and y would be another set. It makes for pretty use

TDPL at its 100,000 words anniversary!

2009-10-25 Thread Andrei Alexandrescu
www.erdani.com Time to go to sleep. Another milestone in store for tomorrow - getting beyond page 300. Andrei

Re: LLVM 2.6 Release!

2009-10-25 Thread Christian Kamm
dsimcha wrote: Other than possible lack of manpower, I don't see why the LDC people don't just use setjmp/longjmp exception handling in the interim. It seems like a good better than nothing solution until LLVM gets fixed properly. The reason *is* lack of manpower. No one has volunteered to

Restricting ++ and --

2009-10-25 Thread bearophile
This post is born from a bug I've just removed. In the past I have read more than one C coding standard (or better, lists of coding tips) that warn against bugs caused by ++ and --. They suggest to not use them compound in expressions. They allow to use them when alone on an instruction.

Re: Restricting ++ and --

2009-10-25 Thread d-noob
bearophile Wrote: This post is born from a bug I've just removed. In the past I have read more than one C coding standard (or better, lists of coding tips) that warn against bugs caused by ++ and --. They suggest to not use them compound in expressions. They allow to use them when alone on

Re: Restricting ++ and --

2009-10-25 Thread Vladimir Panteleev
On Sun, 25 Oct 2009 12:33:13 +0200, bearophile bearophileh...@lycos.com wrote: - Make them return void, so they can't be used as expressions like this: y = x++; foo(x--); You have to use them as: x++; y = x; x--; foo(x); (So ++ and -- become similar to the Inc() and Dec() functions of

Disallow catch without parameter (LastCatch)

2009-10-25 Thread grauzone
Right now, you can catch every exception with try { something; } catch { somethingelse; }. Can we get rid of this abomination before D2 is finalized? I claim that it's completely useless, and even more so, every single use of this is a bug. If you really want to catch everything, you might

Re: Restricting ++ and --

2009-10-25 Thread bearophile
d-noob: That would break C compatibility and sounds ridiculous. It breaks C compatibility, but it doesn't assign a new meaning to a C syntax, it just disallows a syntax used in C, and this is allowed by D philosophy. Many of the things I say sound ridiculous :-) You may say it's not a handy

Re: Restricting ++ and --

2009-10-25 Thread grauzone
d-noob wrote: bearophile Wrote: This post is born from a bug I've just removed. In the past I have read more than one C coding standard (or better, lists of coding tips) that warn against bugs caused by ++ and --. They suggest to not use them compound in expressions. They allow to use them

Re: IDE for D? Recommendations?

2009-10-25 Thread Anders F Björklund
Tiago Carvalho wrote: I don't know about the D support, but codeblocks is not really outdated. If you get the nightly builds the last version is from October 10 2009. They are usually very stable (full with bug fixes and new features), by now I would say even more than the version in the main

Re: Restricting ++ and --

2009-10-25 Thread Peter C. Chapin
bearophile bearophileh...@lycos.com wrote in news:hc19h9$ih...@digitalmars.com: Removing those operators from D, as Python, may look excessive. So a possible compromise can be: - Deprecate the pre versions: --x and ++x - Make them return void, so they can't be used as expressions like

Re: Restricting ++ and --

2009-10-25 Thread d-noob
bearophile Wrote: d-noob: That would break C compatibility and sounds ridiculous. It breaks C compatibility, but it doesn't assign a new meaning to a C syntax, it just disallows a syntax used in C, and this is allowed by D philosophy. Many of the things I say sound ridiculous :-) You

Re: Restricting ++ and --

2009-10-25 Thread Justin Johansson
bearophile Wrote: This post is born from a bug I've just removed. In the past I have read more than one C coding standard (or better, lists of coding tips) that warn against bugs caused by ++ and --. They suggest to not use them compound in expressions. They allow to use them when alone on

Re: Restricting ++ and --

2009-10-25 Thread Lutger
bearophile wrote: This post is born from a bug I've just removed. In the past I have read more than one C coding standard (or better, lists of coding tips) that warn against bugs caused by ++ and --. They suggest to not use them compound in expressions. They allow to use them when alone on

Re: Disallow catch without parameter (LastCatch)

2009-10-25 Thread Leandro Lucarella
grauzone, el 25 de octubre a las 12:09 me escribiste: Right now, you can catch every exception with try { something; } catch { somethingelse; }. Can we get rid of this abomination before D2 is finalized? I claim that it's completely useless, and even more so, every single use of this is a

langref.org: cookbook/programming examples

2009-10-25 Thread Walter Bright
http://langref.org/ Need some D versions!

Re: Restricting ++ and --

2009-10-25 Thread Rainer Deyke
bearophile wrote: Removing those operators from D, as Python, may look excessive. So a possible compromise can be: - Deprecate the pre versions: --x and ++x There is nothing wrong with the prefix versions. '--x' is the equivalent of 'x -= 1', but with less excessive typing. Any confusing

Re: Restricting ++ and --

2009-10-25 Thread dsimcha
== Quote from bearophile (bearophileh...@lycos.com)'s article d-noob: That would break C compatibility and sounds ridiculous. It breaks C compatibility, but it doesn't assign a new meaning to a C syntax, it just disallows a syntax used in C, and this is allowed by D philosophy. Many of the

Tango version poll

2009-10-25 Thread Nick Sabalausky
I've been wondering which is more commonly used, tango 0.99.8 or trunk, so I set up a little poll: http://www.micropoll.com/akira/mpview/704493-211964 I couldn't find any poll generators that didn't use JS :( (I'll have to make one...) Also, that last answer is just there to try to attract

Re: langref.org: cookbook/programming examples

2009-10-25 Thread downs
Walter Bright wrote: http://langref.org/ Need some D versions! http://rosettacode.org/wiki/Category:D is much more complete.

Re: TDPL at its 100,000 words anniversary!

2009-10-25 Thread Simen Kjaeraas
Andrei Alexandrescu seewebsiteforem...@erdani.org wrote: www.erdani.com Time to go to sleep. Another milestone in store for tomorrow - getting beyond page 300. Andrei Grats! -- Simen

Re: TDPL at its 100,000 words anniversary!

2009-10-25 Thread Denis Koroskin
On Sun, 25 Oct 2009 11:23:48 +0300, Andrei Alexandrescu seewebsiteforem...@erdani.org wrote: www.erdani.com Time to go to sleep. Another milestone in store for tomorrow - getting beyond page 300. Andrei It's page 300 and still no excerpt? :)

Re: Disallow catch without parameter (LastCatch)

2009-10-25 Thread Christopher Wright
grauzone wrote: Right now, you can catch every exception with try { something; } catch { somethingelse; }. Can we get rid of this abomination before D2 is finalized? I claim that it's completely useless, and even more so, every single use of this is a bug. If you really want to catch

Re: TDPL at its 100,000 words anniversary!

2009-10-25 Thread Andrei Alexandrescu
Denis Koroskin wrote: On Sun, 25 Oct 2009 11:23:48 +0300, Andrei Alexandrescu seewebsiteforem...@erdani.org wrote: www.erdani.com Time to go to sleep. Another milestone in store for tomorrow - getting beyond page 300. Andrei It's page 300 and still no excerpt? :) Need my editor's

TDPL reaches Thermopylae level

2009-10-25 Thread Andrei Alexandrescu
303 pages and counting! Andrei

Re: TDPL reaches Thermopylae level

2009-10-25 Thread Walter Bright
Andrei Alexandrescu wrote: 303 pages and counting! Come and get them!

Re: TDPL at its 100,000 words anniversary!

2009-10-25 Thread Denis Koroskin
On Mon, 26 Oct 2009 05:53:23 +0300, Andrei Alexandrescu seewebsiteforem...@erdani.org wrote: Denis Koroskin wrote: On Sun, 25 Oct 2009 11:23:48 +0300, Andrei Alexandrescu seewebsiteforem...@erdani.org wrote: www.erdani.com Time to go to sleep. Another milestone in store for tomorrow -

Re: No header files?

2009-10-25 Thread AJ
Lionello Lunesu l...@lunesu.remove.com wrote in message news:hbulk2$1jt...@digitalmars.com... On 22-10-2009 8:01, Walter Bright wrote: Yigal Chripun wrote: the only valid IMO use case for header files is for linking libs - the compiler can handle just find binary formats for that. I was

Re: No header files?

2009-10-25 Thread AJ
Leandro Lucarella llu...@gmail.com wrote in message news:20091024182205.ga28...@llucax.com.ar... AJ, el 24 de octubre a las 01:44 me escribiste: Leandro Lucarella llu...@gmail.com wrote in message news:20091023125658.ga23...@llucax.com.ar... AJ, el 22 de octubre a las 22:08 me escribiste:

Locally Instantiated Templates

2009-10-25 Thread Ellery Newcomer
Walter alluded to these a while back in one of his Dr Dobbs articles (nested functions, part 2), and this evening I've been playing with them a little. It doesn't look like they be mentioned anywhere in the spec. How do they work? It looks kinda like you would just replace any nonlocal symbol

[Issue 3123] std.algorithm.zip fails on 'lazy' ranges

2009-10-25 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=3123 David Simcha dsim...@yahoo.com changed: What|Removed |Added CC||dsim...@yahoo.com ---

[Issue 3440] New: invalid -X JSON output, a comma is missing

2009-10-25 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=3440 Summary: invalid -X JSON output, a comma is missing Product: D Version: 2.035 Platform: x86 OS/Version: Linux Status: NEW Severity: normal Priority: P2

[Issue 3123] std.algorithm.zip fails on 'lazy' ranges

2009-10-25 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=3123 --- Comment #2 from Kyle Foley k-fo...@onu.edu 2009-10-25 21:08:42 PDT --- Created an attachment (id=481) Zip fixes -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email --- You are receiving this mail because:

[Issue 3123] std.algorithm.zip fails on 'lazy' ranges

2009-10-25 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=3123 --- Comment #3 from Kyle Foley k-fo...@onu.edu 2009-10-25 21:10:50 PDT --- (In reply to comment #1) The problem looks to be a question of whether range.front is an lvalue or not. When range.front is an lvalue, DMD interprets range.front as

[Issue 3123] std.algorithm.zip fails on 'lazy' ranges

2009-10-25 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=3123 --- Comment #4 from Kyle Foley k-fo...@onu.edu 2009-10-25 21:13:39 PDT --- (In reply to comment #2) Created an attachment (id=481) [details] Zip fixes I changed Proxy to store by reference for ranges supporting reference return types and by

[Issue 3441] New: Snow Leopard: Static constructors do not work

2009-10-25 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=3441 Summary: Snow Leopard: Static constructors do not work Product: D Version: 1.050 Platform: All OS/Version: Mac OS X Status: NEW Severity: major Priority: P2