Re: phobos unstable builds

2009-07-13 Thread Lutger
Yes, interested.

Re: modulus redux

2009-07-13 Thread Don
Andrei Alexandrescu wrote: Ok, here's how I rewrote the section on multiplicative operations. The text is hardly intelligible due to all formatting, sorry about that (but it looks much better in a specialized editor). Comments and suggestions welcome. \subsection{Multiplicative Expressions}

Re: Can we fix reverse operator overloading (opSub_r et. al.)?

2009-07-13 Thread Lars T. Kyllingstad
Robert Jacques wrote: On Fri, 10 Jul 2009 06:24:04 -0400, Lars T. Kyllingstad wrote: There are actually three (four) basic types of vector/matrix multiplication, and the * operator would more or less be fitting for any of them: - element-by-element multiplication, which is what * means now

Re: Oh Dear

2009-07-13 Thread Walter Bright
Daniel Keep wrote: Incidentally, thanks for making DMD work like this, Walter. I have a big, fairly important project that has its own private copy of the entire toolchain so it's compiler version is stable. Absolutely indispensable. :D A long time ago, I got sick of tools that required envi

Re: Can we fix reverse operator overloading (opSub_r et. al.)?

2009-07-13 Thread Daniel Keep
Lars T. Kyllingstad wrote: > Robert Jacques wrote: >> On Fri, 10 Jul 2009 06:24:04 -0400, Lars T. Kyllingstad >> wrote: >>> There are actually three (four) basic types of vector/matrix >>> multiplication, and the * operator would more or less be fitting for >>> any of them: >>>- element-by-e

Re: Can we fix reverse operator overloading (opSub_r et. al.)?

2009-07-13 Thread Lars T. Kyllingstad
Bill Baxter wrote: On Fri, Jul 10, 2009 at 8:15 AM, Andrei Alexandrescu wrote: Don wrote: The other thing that's desperately missing from D is multi-dimensional indexing. What are the limitations of multiple-argument []? Andrei I don't know what Don had in mind, but multi-dimensional slice

Re: Can we fix reverse operator overloading (opSub_r et. al.)?

2009-07-13 Thread Don
Bill Baxter wrote: On Fri, Jul 10, 2009 at 8:15 AM, Andrei Alexandrescu wrote: Don wrote: The other thing that's desperately missing from D is multi-dimensional indexing. What are the limitations of multiple-argument []? Andrei I don't know what Don had in mind, but multi-dimensional slice

Re: Case Range Statement ..

2009-07-13 Thread Don
Michiel Helvensteijn wrote: Andrei Alexandrescu wrote: void main() { foreach_reverse (i; 0.7 .. 100.7) { write(i, " "); } } The last number printed is -0.3. A question if I may. Why does D allow iteration over an interval of floats? A floating point number has no dir

Re: Case Range Statement ..

2009-07-13 Thread Lars T. Kyllingstad
Don wrote: Michiel Helvensteijn wrote: Andrei Alexandrescu wrote: void main() { foreach_reverse (i; 0.7 .. 100.7) { write(i, " "); } } The last number printed is -0.3. A question if I may. Why does D allow iteration over an interval of floats? A floating point numbe

Re: modulus redux

2009-07-13 Thread Michiel Helvensteijn
Andrei Alexandrescu wrote: > The multiplicative expressions are multiplication (\ccbox{a * b}), > division (\ccbox{a / b}), and remainder (\ccbox{a \% b}). They > operate on numeric types only. The result type of either of these > operations is same as the type of \ccbox

Re: modulus redux

2009-07-13 Thread Andrei Alexandrescu
Don wrote: Close, but that's technically not true in the case where abs(a/b) > long.max. (The integer doesn't have to fit into a 'long'). But if real is 79-bit long (as on Intel), the largest integer that could fit without loss in 1 << 63, and that would fit in a long. Are you saying r could

Re: modulus redux

2009-07-13 Thread Andrei Alexandrescu
Michiel Helvensteijn wrote: Andrei Alexandrescu wrote: The multiplicative expressions are multiplication (\ccbox{a * b}), division (\ccbox{a / b}), and remainder (\ccbox{a \% b}). They operate on numeric types only. The result type of either of these operations is same as

Re: modulus redux

2009-07-13 Thread Steven Schveighoffer
On Mon, 13 Jul 2009 08:51:06 -0400, Andrei Alexandrescu wrote: Michiel Helvensteijn wrote: Andrei Alexandrescu wrote: The multiplicative expressions are multiplication (\ccbox{a * b}), division (\ccbox{a / b}), and remainder (\ccbox{a \% b}). They operate on numeric types onl

Re: Case Range Statement ..

2009-07-13 Thread Bill Baxter
On Mon, Jul 13, 2009 at 2:59 AM, Don wrote: > Michiel Helvensteijn wrote: >> >> Andrei Alexandrescu wrote: >> >>> void main() >>> { >>>     foreach_reverse (i; 0.7 .. 100.7) >>>     { >>>         write(i, " "); >>>     } >>> } >>> >>> The last number printed is -0.3. >> >> A question if I may. >> >

Conditional compilation inside asm and enum declarations

2009-07-13 Thread Julian Salazar
Hi, I'm new here to the community but I've been using D for a while now, and I have to say that it's a great programming language. I'd like to get involved in this community and help shape this language. I'm just wondering about a minor issue: why are conditional blocks invalid within expressi

Re: Conditional compilation inside asm and enum declarations

2009-07-13 Thread Jarrett Billingsley
On Mon, Jul 13, 2009 at 11:15 AM, Julian Salazar wrote: > Hi, I'm new here to the community but I've been using D for a while now, and > I have to say that it's a great programming language. I'd like to get > involved in this community and help shape this language. Man, so would I ;) > I'm just w

Re: Conditional compilation inside asm and enum declarations

2009-07-13 Thread Andrei Alexandrescu
Julian Salazar wrote: Hi, I'm new here to the community but I've been using D for a while now, and I have to say that it's a great programming language. I'd like to get involved in this community and help shape this language. [snip] Great! This is the place to effect that, and the improvement

Re: Conditional compilation inside asm and enum declarations

2009-07-13 Thread Walter Bright
Julian Salazar wrote: Hi, I'm new here to the community but I've been using D for a while now, and I have to say that it's a great programming language. I'd like to get involved in this community and help shape this language. Welcome! I'm just wondering about a minor issue: why are condition

Re: modulus redux

2009-07-13 Thread Walter Bright
Don wrote: Close, but that's technically not true in the case where abs(a/b) > long.max. (The integer doesn't have to fit into a 'long'). In IEEE754, r= a % b is defined by the mathematical relation r = a – b * n , where n is the integer nearest the exact number a/b ; whenever abs( n – a/b

Re: modulus redux

2009-07-13 Thread Walter Bright
Andrei Alexandrescu wrote: Don wrote: Close, but that's technically not true in the case where abs(a/b) > long.max. (The integer doesn't have to fit into a 'long'). But if real is 79-bit long (as on Intel), the largest integer that could fit without loss in 1 << 63, and that would fit in a lo

Re: modulus redux

2009-07-13 Thread Andrei Alexandrescu
Walter Bright wrote: Andrei Alexandrescu wrote: Don wrote: Close, but that's technically not true in the case where abs(a/b) > long.max. (The integer doesn't have to fit into a 'long'). But if real is 79-bit long (as on Intel), the largest integer that could fit without loss in 1 << 63, and

Re: Conditional compilation inside asm and enum declarations

2009-07-13 Thread bearophile
Walter Bright: > The first approximation to the definition is to use the Intel asm syntax > as outlined in their processor data sheets. I haven't written a spec > more detailed than that because it's a lot of work and I'm lazy, and > such work is not terribly exciting. But if you'd like to help

Re: modulus redux

2009-07-13 Thread Walter Bright
Andrei Alexandrescu wrote: http://d.puremagic.com/issues/show_bug.cgi?id=3171 What are friends for? Ridiculing the cars my friends drive, of course!

Patronizing Language Design?

2009-07-13 Thread Walter Bright
Here's certainly a different take on language design: http://blog.objectmentor.com/articles/2009/07/13/ending-the-era-of-patronizing-language-design I'm not convinced. All my engineering experience supports the idea that the larger the project and the more people are involved in it, the better

Re: Patronizing Language Design?

2009-07-13 Thread Paul D. Anderson
Walter Bright Wrote: > Here's certainly a different take on language design: > > http://blog.objectmentor.com/articles/2009/07/13/ending-the-era-of-patronizing-language-design > > I'm not convinced. All my engineering experience supports the idea that > the larger the project and the more peopl

Re: Patronizing Language Design?

2009-07-13 Thread Nick Sabalausky
"Walter Bright" wrote in message news:h3g51a$2e3...@digitalmars.com... > Here's certainly a different take on language design: > > http://blog.objectmentor.com/articles/2009/07/13/ending-the-era-of-patronizing-language-design > > I'm not convinced. All my engineering experience supports the idea

Re: Patronizing Language Design?

2009-07-13 Thread bearophile
Walter Bright: > What are your experiences?< Michael Feathers is talking about Ruby; in the Python community there's even a say about this subject: "We are all consenting adults". It means that you usually don't need private class attributes, you can just put an underscore (or even two, for nam

Re: Patronizing Language Design?

2009-07-13 Thread Nick Sabalausky
"Nick Sabalausky" wrote in message news:h3ga75$2n4...@digitalmars.com... > "Walter Bright" wrote in message > news:h3g51a$2e3...@digitalmars.com... >> Here's certainly a different take on language design: >> >> http://blog.objectmentor.com/articles/2009/07/13/ending-the-era-of-patronizing-langu

Re: Patronizing Language Design?

2009-07-13 Thread Adam D. Ruppe
On Mon, Jul 13, 2009 at 05:50:25PM -0400, Nick Sabalausky wrote: > Also, maybe I'm wrong, but doesn't Ruby (and Python for that matter) lack > direct memory access/management, reinterpret casts, etc? They don't even have goto, surely because they think people would abuse it. -- Adam D. Ruppe

Re: Patronizing Language Design?

2009-07-13 Thread Rainer Deyke
Walter Bright wrote: > What are your experiences? Not all safety features are patronizing. Safety features allow the compiler to partially check the correctness of the program. Patronizing safety features prevent the programmer from doing their job. Having no way to specify const data is danger

Re: Patronizing Language Design?

2009-07-13 Thread Lutger
Reminds me of this from Bartosz' site: "If you're a fan of object-oriented programming, you might find this quotation from the MFC's official Guidelines for Writing Class Library Extensions pretty amusing. Limit the Use of "Private" in Your Classes. It is important that your users be able

Compiler Page - Request for review

2009-07-13 Thread Jesse Phillips
I've created a small overview page of the available compilers on Wiki4D. The idea is not to contain much concrete information, but point users in the correct direction. However, for the information that is there I want to make sure that it is correct and clear what is being stated. Thank you h

Re: Compiler Page - Request for review

2009-07-13 Thread Lutger
Some comments: dil is not yet able to compile D as far as I know, which is what the page suggest ("There are a number of compilers that can be used for D") The dmd table could suggest that it supports D2 with Tango, I recommend formatting it like this: language version D1.x D2.x ru

Re: Compiler Page - Request for review

2009-07-13 Thread Lutger
... > About GDC, iirc the latest (which is quite old) version can be used with a > version of D, although I don't remember which one. a version of *D2*

Re: Patronizing Language Design?

2009-07-13 Thread BCS
Hello Nick, let me do what I want, but if I'm doing something questionable, make sure I'm at least aware of it. Bingo! The only language you /can't/ write bugs in is HQ9+ http://esolangs.org/wiki/HQ9_Plus Just about any time you stop me from doing something because you think it's a bug, yo

Re: Conditional compilation inside asm and enum declarations

2009-07-13 Thread Julian Salazar
"Walter Bright" wrote in message news:h3fu36$22h...@digitalmars.com... Welcome! A welcome from the guy who actually created the D language - thanks! The request to do it for enums has been thrashed about before. Essentially, version works at the declaration and statement level, not at the e

Re: Compiler Page - Request for review

2009-07-13 Thread Robert Clipsham
Jesse Phillips wrote: I've created a small overview page of the available compilers on Wiki4D. The idea is not to contain much concrete information, but point users in the correct direction. However, for the information that is there I want to make sure that it is correct and clear what is bei

Re: Compiler Page - Request for review

2009-07-13 Thread Robert Clipsham
Lutger wrote: Some comments: dil is not yet able to compile D as far as I know, which is what the page suggest ("There are a number of compilers that can be used for D") That's correct, it's lacking in the semantic analysis required to be a complete frontend, and even then it still needs a b

Re: Compiler Page - Request for review

2009-07-13 Thread Leandro Lucarella
Robert Clipsham, el 14 de julio a las 00:43 me escribiste: > Lutger wrote: > >Some comments: dil is not yet able to compile D as far as I know, which > >is what the page suggest ("There are a number of compilers that can be > >used for D") > > That's correct, it's lacking in the semantic analysis

Re: Patronizing Language Design?

2009-07-13 Thread BLS
Walter Bright wrote: the larger the project and the more people are involved in it, the better off you are with isolation between modules and better enforcement of interfaces. It's not about language design , what I have to say is more about complex software systems in general. f.i. we are de

Re: Compiler Page - Request for review

2009-07-13 Thread Tim Matthews
Jesse Phillips wrote: I've created a small overview page of the available compilers on Wiki4D. The idea is not to contain much concrete information, but point users in the correct direction. However, for the information that is there I want to make sure that it is correct and clear what is bei

Re: Patronizing Language Design?

2009-07-13 Thread Walter Bright
Rainer Deyke wrote: Not all safety features are patronizing. Safety features allow the compiler to partially check the correctness of the program. Patronizing safety features prevent the programmer from doing their job. Having no way to specify const data is dangerous. Having no way to cast

Optimizing Scala

2009-07-13 Thread bearophile
Instead of following the suggestions that Andrei has given me three or four times (to not pass delegates/function to higher-order functions, but use aliases), Scala designers have chosen to create a smarter compiler: "Optimizing Higher-Order Functions in Scala", by Iulian Dragoş: http://infoscien

Re: Compiler Page - Request for review

2009-07-13 Thread Jesse Phillips
On Tue, 14 Jul 2009 00:17:52 +0100, Robert Clipsham wrote: > http://docs.google.com/Doc?id=dghphd83_43ffpdbtcc might help with that > page (although it's slightly out of date now). I find the tables > slightly confusing, I read that as dmd 2 using tango as its runtime > library, it'd be nice if it

Re: Compiler Page - Request for review

2009-07-13 Thread Jesse Phillips
On Tue, 14 Jul 2009 00:48:56 +0200, Lutger wrote: > Some comments: > > dil is not yet able to compile D as far as I know, which is what the > page suggest ("There are a number of compilers that can be used for D") Good point, I want to include it in the list since it is active and attempts to u

Re: Compiler Page - Request for review

2009-07-13 Thread Jesse Phillips
On Tue, 14 Jul 2009 12:42:53 +1200, Tim Matthews wrote: > Jesse Phillips wrote: >> I've created a small overview page of the available compilers on >> Wiki4D. The idea is not to contain much concrete information, but point >> users in the correct direction. However, for the information that is >>

Re: Conditional compilation inside asm and enum declarations

2009-07-13 Thread Walter Bright
Julian Salazar wrote: Maybe it's time for some maintenance? Or a rewrite in a certain higher-level language? ;) Yes, but to rewrite it requires understanding it, and that means obj2asm. So, in essence, the idea is to push conditional compilation to higher levels, not lower levels. Ideally, ve

Re: DIP3 - Remove inheritance protection

2009-07-13 Thread Lars T. Kyllingstad
Brad Roberts wrote: For grins (and to see how well this process might work), I lifted a bugzilla issue (177) into a DIP: http://www.prowiki.org/wiki4d/wiki.cgi?LanguageDevel/DIPs/DIP3 It's a suggestion to remove a feature that several consider to be of little if any value. Obviously it's so