Re: temporary objects are not allowed to be pass by ref anymore

2009-04-20 Thread Lutger
Andrei Alexandrescu wrote: ... Now onto why ref was disallowed to bind to an rvalue. This is because some functions take things by ref intending to change them. Passing an rvalue is in such cases a bug. I agree there are functions that only want to use ref for speed purposes. I suggested

Re: Multithreaded I/O in the DMD compiler (DDJ article by Walter)

2009-04-08 Thread Lutger
Steven Schveighoffer wrote: On Tue, 07 Apr 2009 13:56:34 -0400, grauzone n...@example.net wrote: only thing it lacks is iTunes (yeah, screw you, I like iTunes :) and it There are lots of iTunes clones. Maybe you should try to get used to one of them? I'm sorry, but I'm ignorant of

Re: The new, new phobos sneak preview

2009-04-07 Thread Lutger
This is looking very impressive, will you be covering some of these concepts and idioms used in phobos in your upcoming TDPL? This url returns a 404: http://www.erdani.dreamhosters.com/d/web/phobos/std_patterns.html

Re: Multithreaded I/O in the DMD compiler (DDJ article by Walter)

2009-04-07 Thread Lutger
grauzone wrote: Andrei Alexandrescu wrote: grauzone wrote: I'm not expecting anything from Linux GUIs anymore. Seriously, Linux on the desktop sucks. God, does it suck! What standard are you holding it against? The Mac GUI is snappier, but First, I didn't ever use a Mac. Hell, these

Re: Multithreaded I/O in the DMD compiler (DDJ article by Walter)

2009-04-07 Thread Lutger
Walter Bright wrote: ... I find myself more and more switching back and forth between the two for specific tasks (I use a KVM switch to go back and forth). Have you ever tried virtualbox? It has a seamless mode, which tears out windows apps in the virtual instance and make them behave just as

Re: How about a compatibility list?

2009-03-28 Thread Lutger
Christopher Wright wrote: Nick Sabalausky wrote: Saaa em...@needmail.com wrote in message news:gqjjp3$jr...@digitalmars.com... Who is going to do the work of reviewing these libraries for compatibility? The people :) like in the wine database. I would think some of that work could be

getting mutable type from T

2009-03-24 Thread Lutger
How can I get the mutable type from any type T in a generic function or template, assuming T is const or immutable?

Re: getting mutable type from T

2009-03-24 Thread Lutger
Jarrett Billingsley wrote: .. std.traits.Mutable!(T). Ah thanks! Too obvious. In case somebody would like to know: static if (is(T U == const(U))) alias U Mutable; else static if (is(T U == immutable(U))) alias U Mutable;

Re: What is the sate of LDC?

2009-03-24 Thread Lutger
bearophile wrote: .. (Eventually I'd like to see a project like dlang, a D clang-like front-end for LLVM written in D, replace LDC, but this will require a ton of work. So it's mostly a dream now). Sounds like dil: http://code.google.com/p/dil/

Re: libpthread linker error

2009-03-09 Thread Lutger
dsimcha wrote: == Quote from Walter Bright (newshou...@digitalmars.com)'s article Looks like you're trying to link with the 64 bit library when you need the 32 bit one. x86_64 means 64 bits. The 32 bit versions may not be installed. Duh, didn't notice that x86_64 in there. Good call. I

Re: const?? When and why? This is ugly!

2009-03-07 Thread Lutger
Walter Bright wrote: ... The way to do strings in D is to have them be immutable. If you are building a string by manipulating its parts, start with mutable, when finished then convert it to immutable and 'publish' it to the rest of the program. Mutable char[] arrays should only exist as

Re: const?? When and why? This is ugly!

2009-03-04 Thread Lutger
hasen wrote: Walter Bright wrote: grauzone wrote: I didn't mean going back to programming with locks. Instead you could use the new ideas without extending the type system. As far as I understand, the language extensions are only needed for verification (so far). Without verification,

Re: Important contributions to D by non-guru programmers!

2009-03-01 Thread Lutger
Georg Wrede wrote: The subject sounds like spam, I know. :-) I was browsing http://en.wikibooks.org/wiki/Algorithms and noticed that the appendix contains example code in Ada. Having them written in D would serve several goals: - More clear, since D code is very near the Pseudocode

Re: Resizable Arrays?

2009-03-01 Thread Lutger
bearophile wrote: Jason HouseBy dynamic, do you mean no length as part of the type or resizable in place? Array resizing can lead to hidden allocations, Thy aren't hidden: when you grow a dynamic array you know an allocation generally takes place. If you don't want reallocations, then never

Re: CUDA with D?

2009-03-01 Thread Lutger
Chris R Miller wrote: ... I looked into OpenCL, which appears (at first glance) to be a funky way of stringing together assembler instructions using C function calls. I'm sure it's fast, but it's not the most friendly looking code to me (then again, I don't know ASM, so what do I know?)

Re: finding dmd.conf

2009-02-28 Thread Lutger
Jesse Phillips wrote: On Fri, 27 Feb 2009 15:54:46 +0100, Lutger wrote: I'm having some trouble with dmd.conf. I set up a (soft) symbolic link to the dmd/bin path version I want to use, but dmd can't find dmd.conf: $ which dmd /home/lutger/code/bin/dmd/bin/dmd $ dmd main.d

Re: First class lazy Interval

2009-02-27 Thread Lutger
bearophile wrote: Michel Fortin: ... Perhaps we could make 3 dots mean an inclusive interval (including the second value in the interval), and 2 dots an exclusive one (excluding the second value). Ruby follows your idea, but for the eye it's easy to miss the extra dot, so I don't like

Re: finding dmd.conf

2009-02-27 Thread Lutger
Moritz Warning wrote: ... Have you tried to add your dmd/bin to your PATH environment variable? Yes it's there and dmd got properly picked up by the 'which' command.

Re: [Issue 2690] New: DMD aborts with MALLOC_CHECK_ set

2009-02-27 Thread Lutger
Denis Koroskin wrote: On Thu, 26 Feb 2009 02:27:43 +0300, Lutger lutger.blijdest...@gmail.com wrote: Also happens in dmd 2.025 When MALLOC_CHECK_ set to 1, I get the following message: *** glibc detected *** dmd: realloc(): invalid pointer: 0x08d2c6a8 *** Segmentation fault Perhaps

Re: Beginning with D

2009-02-26 Thread Lutger
Tim M wrote: On Fri, 27 Feb 2009 01:42:17 +1300, bearophile bearophileh...@lycos.com wrote: Rainer Deyke: My opinion: D 1.0 is, on the whole, worse than C++. There are many things in D1 better than C++, in particular you need less time learn the language and less time to write

Re: Beginning with D

2009-02-26 Thread Lutger
Jason House wrote: Lutger Wrote: Tim M wrote: ... D2 what other features does C++ have over D? The most prominent feature is value semantics for classes I don't agree with this one. Classes and structs are identical in C++ (except for default protection). In D, they differ

Re: [Issue 2690] New: DMD aborts with MALLOC_CHECK_ set

2009-02-25 Thread Lutger
Also happens in dmd 2.025 When MALLOC_CHECK_ set to 1, I get the following message: *** glibc detected *** dmd: realloc(): invalid pointer: 0x08d2c6a8 *** Segmentation fault

Re: Any way to track memory allocations?

2009-02-24 Thread Lutger
Jarrett Billingsley wrote: On Tue, Feb 24, 2009 at 12:00 PM, wade Shen swadena...@gmail.com wrote: I'm writing some performance sensitive code (real time processing) for which I've tried to minimize the number of memory allocations by using preallocated objects pools.  Unfortunately, during

Re: CUDA with D?

2009-02-23 Thread Lutger
Chris R Miller wrote: Trass3r wrote: Is there any tutorial or code for using CUDA with D? Short answer: no. I looked into writing CUDA with D a while back. The problem is that the CUDA C runtime and the D runtime are 100% incompatible. CUDA works by taking C-like code and compiling

Re: Unicode problems?

2009-02-16 Thread Lutger
Trass3r wrote: Wikipedia states that D still has some Unicode problems: Operations on Unicode strings are unintuitive (compiler accepts Unicode source code, standard library and foreach constructs operate on UTF-8, but string slicing and length property operate on bytes rather than

Re: Why version() ?

2009-02-10 Thread Lutger
bobef wrote: I was thinking... what is the point of version() ? It is so inflexible. There is no even version(!...). Why not static if(version(DMD)) or static if(is(version == DMD))? Regards, bobef What would be the difference except more verbosity? You can use version(x) { } else { }

Re: OpenCL bindings

2009-02-10 Thread Lutger
Trass3r wrote: Has anyone already started creating some OpenCL bindings for D? Is there an implementation already?

Re: switch off GC?

2009-02-05 Thread Lutger
Weed wrote: I just would like that D could substitute C++ completely in all applications... D2 can easily, but it seems there is not so much interest if measured by what library code is available. D1 can do too, but if you want to use raii for memory management D2 has better facilities. In

Re: Descent 0.5.4 released

2009-01-27 Thread Lutger
How wonderful, thank you VERY much! OT: I've found eclipse 3.4.x under 64-bit linux less than stable with descent, but the 3.5 stream release works pretty good so far.

bcdgen and gccxml: detecting parse errors?

2009-01-26 Thread Lutger
When bcdgen parses a header file with errors, it still completes the translation. Is there a way I can get bcdgen to error out? I think it's a gccxml thing, for even while detecting errors it returns 0. The problem is that some projects seem to have header files which are only useful if

Re: bcdgen and gccxml: detecting parse errors?

2009-01-26 Thread Lutger
So it was my error, some modifications I made to bcdgen. Sorry for the noise. * why is it that these dumb mistakes always get apparent at once AFTER posting ...*

Re: Ada Vs C (with some D mixed in)

2009-01-19 Thread Lutger
bearophile wrote: Walter Bright: SafeD is about guaranteeing memory safety, not other issues like integer overflows. Memory safety is a fairly specifically defined thing. Then maybe the name of SafeD isn't too much good, because when I hear that name I think about a safe(r) language, and

Re: loop through specific class members

2009-01-19 Thread Lutger
Trass3r wrote: Daniel Keep schrieb: Assuming you're using D2, http://digitalmars.com/d/2.0/traits.html might prove to be of interest. -- Daniel It is indeed of interest though being not exactly what I want. Seems like there's currently no way to get attributes like public etc. But

Re: How to size optimize the executable?

2009-01-14 Thread Lutger
Claus D. Volko wrote: What bothers me about D is that the executables dmd generates are quite large. Some simple programs have almost 200 kb. I've tried packing them with kkrunchy, the result are still about 100 kb. By contrast, with Visual C++ such programs would be only a few kbytes (in

Re: Qt 4.5 to be LGPL

2009-01-14 Thread Lutger
Nick Sabalausky wrote: Bill Baxter wbax...@gmail.com wrote in message news:mailman.400.1231947622.22690.digitalmar...@puremagic.com... Qt 4.5 to be LGPL http://tech.slashdot.org/article.pl?sid=09%2F01%2F14%2F1312210 Now we just need a D port... ...and a sponsor to make the port? I wonder

Re: Hello .NET, D Here Calling

2008-12-23 Thread Lutger
Daniel de Kok wrote: With no intention to flame, but I never quite understood why people are so keen on properties over getter/setter member functions. What advantage does it have over obscuring direct member access and indirect member access? This 'obscuring' is exactly what makes

Re: Descent 0.5.3 released

2008-12-21 Thread Lutger
Thank you so much, I really appreciate this IDE. What would make me most happy, personally, is getting Descent to parse command line output from dmd and jump to errors in the source file. Next up the wishlist is actually building from Descent, but this is less important. Dsss support would

Re: exe file size

2008-11-30 Thread Lutger
Bill Baxter wrote: ... Build times with the new dsss push me way past the sanity point, so I've gone back to 0.76, which I think may have never been released. I think I built it myself from sources. Build times with 0.76 are just barely tolerable with my app. But my colleague was telling

Re: DMD 1.037 and 2.020 releases

2008-11-26 Thread Lutger
Great release, thank you!

Re: should D have a set of tutorials for it?

2008-11-22 Thread Lutger
Surely more tutorials is a good idea. Writing good tutorials is difficult though, and a lot of work. Have you considered contributing to this wikibook instead? http://en.wikibooks.org/wiki/A_Beginner%27s_Guide_to_D It states the intended audience includes people new to programming.

Re: How much time will D1 be around?

2008-11-13 Thread Lutger
Peter Venkman wrote: So, for me the question would be, when will D2 support come to existing libraries -at least the most popular ones-? A lot of libraries depend on tango, so I wouldn't expect too much support before a D2 Tango is released.

<    2   3   4   5   6   7