Re: DIP11

2011-08-12 Thread Jacob Carlborg
On 2011-08-11 20:31, Steven Schveighoffer wrote: On Thu, 11 Aug 2011 14:19:35 -0400, Jacob Carlborg wrote: So how would that be different if the compiler drives everything? Say you begin with a few local files. The compiler then scans through them looking for URL imports. Then asks a tool to do

Github Reminder

2011-08-12 Thread Jonathan M Davis
Pull requests for Phobos and druntime need to be reviewed before they get merged in. Ideally, every pull request would be reviewed by at least two Phobos devs before being merged in, but anyone is welcome to review pull requests for druntime and Phobos and give constructive feedback. It will hel

Re: Std.path: Final Vote

2011-08-12 Thread Rainer Schuetze
Yes

Re: std.path review: final version(?)

2011-08-12 Thread Rainer Schuetze
I like how std.path has turned out. Thanks, Lars. Two minor issues while skipping through the source (I've been on vacation, and it took some time to catch up, so I'm not sure these have already been discussed): - C[] baseName(C, C1)(C[] path, C1[] suffix) does not respect the case sensitiv

Re: std.path review: final version(?)

2011-08-12 Thread Jonathan M Davis
On Friday, August 12, 2011 10:14:11 Rainer Schuetze wrote: > I like how std.path has turned out. Thanks, Lars. > > Two minor issues while skipping through the source (I've been on > vacation, and it took some time to catch up, so I'm not sure these have > already been discussed): > > - C[] baseNa

Re: DIP11

2011-08-12 Thread Jacob Carlborg
On 2011-08-11 21:36, Steven Schveighoffer wrote: be one-file based, you just need to have a way to map physical packages to module packages. The DIP doesn't explain all this except for the sections titled "Packaging" and "protocols" The DIP needs to explain this, is that the whole point? -- /

Re: DIP11

2011-08-12 Thread Jacob Carlborg
On 2011-08-11 23:02, Andrei Alexandrescu wrote: It's difficult to get all dependencies when not all sources have been yet downloaded. Andrei No, not when you have a single meta file containing all the dependencies of all packages. -- /Jacob Carlborg

Re: DIP11

2011-08-12 Thread Jacob Carlborg
On 2011-08-11 23:30, Nick Sabalausky wrote: "Jacob Carlborg" wrote in message news:j21190$ls8$1...@digitalmars.com... Assuming that, you would still need to link with the libraries. I don't know if pragma(lib, ""); could work but I don't like that pragma in general. It's platform dependent T

Re: DIP11

2011-08-12 Thread Jacob Carlborg
On 2011-08-12 00:02, Steven Schveighoffer wrote: On Thu, 11 Aug 2011 17:20:04 -0400, Nick Sabalausky wrote: "Andrei Alexandrescu" wrote in message news:j21g1a$ea4$1...@digitalmars.com... It's difficult to get all dependencies when not all sources have been yet downloaded. With DIP11, yes

Re: DIP11

2011-08-12 Thread Jacob Carlborg
On 2011-08-12 00:42, Martin Nowak wrote: It really looks sound to me. --- module myfile; pragma(imppath, "dep=www.dpan.org/dep"); import dep.a; --- remote file --- module dep.a; // link directives pragma(libpath, "dep=www.dpan.org/dep"); pragma(lib, "dep"); // or alternatively some new pragma

Re: DIP11

2011-08-12 Thread Jacob Carlborg
On 2011-08-12 08:17, kennytm wrote: "Steven Schveighoffer" wrote: On Thu, 11 Aug 2011 17:20:04 -0400, Nick Sabalausky wrote: "Andrei Alexandrescu" wrote in message news:j21g1a$ea4$1...@digitalmars.com... It's difficult to get all dependencies when not all sources have been>> yet download

Re: DIP11

2011-08-12 Thread David Nadlinger
On 8/12/11 11:05 AM, Jacob Carlborg wrote: On 2011-08-11 23:02, Andrei Alexandrescu wrote: It's difficult to get all dependencies when not all sources have been yet downloaded. Andrei No, not when you have a single meta file containing all the dependencies of all packages. Or a »spec« file

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread Don
bearophile wrote: I have added this bit of code to my dmd, it gives warnings in cases of integral signed-unsigned comparisons: https://github.com/D-Programming-Language/dmd/pull/119 Then I have compiled Phobos (with unittests) with the -wi switch, this has generated some of those signed-unsign

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread kennytm
Don wrote: > I've had a look at a dozen or so of these, and they were all real. I > didn't see any which require a cast to "make the compiler shut up". > That's pretty impressive. In C++ I find that such messages are nearly > always false positives. > > The one case where it's a bit annoying is

Re: Run Microsoft Analyzer over dmd source code

2011-08-12 Thread David Nadlinger
On 8/7/11 9:47 PM, Vladimir Panteleev wrote: http://thecybershadow.net/d/vcanalysis/ http://dump.thecybershadow.net/b1e4cb6ef0a8d3c5f54d5cb09ddd1a9e/DMD.log Is there a way to disable exceptions with MSVC like -fno-exceptions for GCC to help get rid of the associated false positives? David

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread Don
kennytm wrote: Don wrote: I've had a look at a dozen or so of these, and they were all real. I didn't see any which require a cast to "make the compiler shut up". That's pretty impressive. In C++ I find that such messages are nearly always false positives. The one case where it's a bit annoyi

Re: [GSOC] regular expressions beta is here

2011-08-12 Thread Don
bearophile wrote: Don: 2) I have found many situations where I am able to solve a problem with both a simple and slow brute force solver, and a complex and fast algorithm to solve a problem. The little program maybe is too much slow for normal usage, but it's just few lines long (especially

std.path Accepted 22-0

2011-08-12 Thread dsimcha
Lars Kyllingstad's new std.path has been approved by the D community by a vote of 22-0. Congratulations, Lars! I look forward to seeing this in the next release

Next to review: Curl Wrapper? (Was: Review Queue Update?)

2011-08-12 Thread dsimcha
On 8/10/2011 9:22 AM, dsimcha wrote: The review of the new std.path is drawing to a close and it looks like another success! (Congratulations, Lars.) Lately, though, the queue of stuff to review has been getting rather long, admittedly a problem we'd like to have. I want to get a list of stuff th

Re: DB ORM

2011-08-12 Thread zhang
> You mean to indicate the attribute doesn't have a value? Yes, the field of a table can be null in DB. -- Zhang

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread Marco Leise
Am 12.08.2011, 12:22 Uhr, schrieb kennytm : Don wrote: I've had a look at a dozen or so of these, and they were all real. I didn't see any which require a cast to "make the compiler shut up". That's pretty impressive. In C++ I find that such messages are nearly always false positives. The on

Re: [GSOC] regular expressions beta is here

2011-08-12 Thread Timon Gehr
On 08/12/2011 01:31 PM, Don wrote: bearophile wrote: Don: 2) I have found many situations where I am able to solve a problem with both a simple and slow brute force solver, and a complex and fast algorithm to solve a problem. The little program maybe is too much slow for normal usage, but it's

Re: DB ORM

2011-08-12 Thread zhang
> Graham Fawcett wrote. > > On Thu, 11 Aug 2011 20:10:15 +0800, zhang wrote: > > > >>> > I think D needs user defined attributes first. > >> > >> About attribute, here is an example: > >> > >> > >> > >> There is a problem that is D's basic type is not nullable. In C#, > >> the nullable integer

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread bearophile
Marco Leise: > Just remember that reverse loops are written like this: > > for (size_t i = x.length; i-- > 0; ) {...} Thankfully in D there is foreach_reverse :-) import std.stdio; void main() { auto array = [10, 20, 30]; for (size_t i = array.length; i-- > 0; ) writeln(i, " "

C1X memory-order in C1X

2011-08-12 Thread bearophile
I have found this though Reddit, I am not expert about this stuff, but it's something for the design of the next C (C1X), about memory-order options: http://www.open-std.org/JTC1/SC22/WG14/www/docs/n1525.htm Bye, bearophile

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread Timon Gehr
On 08/12/2011 03:08 PM, bearophile wrote: Marco Leise: Just remember that reverse loops are written like this: for (size_t i = x.length; i--> 0; ) {...} Thankfully in D there is foreach_reverse :-) import std.stdio; void main() { auto array = [10, 20, 30]; for (size_t i = array

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread Jacob Carlborg
On 2011-08-12 14:55, Marco Leise wrote: Am 12.08.2011, 12:22 Uhr, schrieb kennytm : Don wrote: I've had a look at a dozen or so of these, and they were all real. I didn't see any which require a cast to "make the compiler shut up". That's pretty impressive. In C++ I find that such messages a

Re: DB ORM

2011-08-12 Thread Jacob Carlborg
On 2011-08-12 14:59, zhang wrote: You mean to indicate the attribute doesn't have a value? Yes, the field of a table can be null in DB. -- Zhang I think you can declare new types for the types found in the database, like String, Integer, Date and so on. You could put additional useful

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread Marco Leise
Am 12.08.2011, 15:08 Uhr, schrieb bearophile : Marco Leise: Just remember that reverse loops are written like this: for (size_t i = x.length; i-- > 0; ) {...} Thankfully in D there is foreach_reverse :-) import std.stdio; void main() { auto array = [10, 20, 30]; for (size_t i = a

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread Timon Gehr
On 08/12/2011 03:33 PM, Marco Leise wrote: Am 12.08.2011, 15:08 Uhr, schrieb bearophile : Marco Leise: Just remember that reverse loops are written like this: for (size_t i = x.length; i-- > 0; ) {...} Thankfully in D there is foreach_reverse :-) import std.stdio; void main() { auto arra

Re: DIP11

2011-08-12 Thread Steven Schveighoffer
On Fri, 12 Aug 2011 03:23:30 -0400, Jacob Carlborg wrote: On 2011-08-11 20:31, Steven Schveighoffer wrote: On Thu, 11 Aug 2011 14:19:35 -0400, Jacob Carlborg wrote: So how would that be different if the compiler drives everything? Say you begin with a few local files. The compiler then scans

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread Marco Leise
Am 12.08.2011, 14:55 Uhr, schrieb Marco Leise : for (size_t i = x.length; i-- > 0; ) {...} Actually this is probably better: for (auto i = x.length; i > 0; ) { --i; ... }

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread Marco Leise
Am 12.08.2011, 15:44 Uhr, schrieb Timon Gehr : On 08/12/2011 03:33 PM, Marco Leise wrote: Am 12.08.2011, 15:08 Uhr, schrieb bearophile : Marco Leise: Just remember that reverse loops are written like this: for (size_t i = x.length; i-- > 0; ) {...} Thankfully in D there is foreach_revers

Re: DIP11

2011-08-12 Thread Steven Schveighoffer
On Fri, 12 Aug 2011 05:12:47 -0400, Jacob Carlborg wrote: On 2011-08-12 00:42, Martin Nowak wrote: It really looks sound to me. --- module myfile; pragma(imppath, "dep=www.dpan.org/dep"); import dep.a; --- remote file --- module dep.a; // link directives pragma(libpath, "dep=www.dpan.org/de

Re: DIP11

2011-08-12 Thread Steven Schveighoffer
On Fri, 12 Aug 2011 05:04:13 -0400, Jacob Carlborg wrote: On 2011-08-11 21:36, Steven Schveighoffer wrote: be one-file based, you just need to have a way to map physical packages to module packages. The DIP doesn't explain all this except for the sections titled "Packaging" and "protocols"

Re: DIP11

2011-08-12 Thread Steven Schveighoffer
On Fri, 12 Aug 2011 02:17:36 -0400, kennytm wrote: "Steven Schveighoffer" wrote: On Thu, 11 Aug 2011 17:20:04 -0400, Nick Sabalausky wrote: > "Andrei Alexandrescu" wrote in > message > news:j21g1a$ea4$1...@digitalmars.com... >> >> It's difficult to get all dependencies when not all sources

Re: std.path Accepted 22-0

2011-08-12 Thread Steven Schveighoffer
On Fri, 12 Aug 2011 08:45:11 -0400, dsimcha wrote: Lars Kyllingstad's new std.path has been approved by the D community by a vote of 22-0. Congratulations, Lars! I look forward to seeing this in the next release Congrats Lars! Just so you know, I was probably a yes vote, but I didn't

Re: DIP11

2011-08-12 Thread Adam D. Ruppe
I did write build2.d, which tries to simulate dip11 outside the compiler. http://arsdnet.net/dcode/build2.d Since it's not actually in the compiler, it can't be perfect but it sorta tries.

Re: DIP11

2011-08-12 Thread Andrei Alexandrescu
On 8/12/11 3:05 AM, Jacob Carlborg wrote: On 2011-08-11 23:02, Andrei Alexandrescu wrote: It's difficult to get all dependencies when not all sources have been yet downloaded. Andrei No, not when you have a single meta file containing all the dependencies of all packages. I understand. I be

Re: Any D developer at GDC europe next week ?

2011-08-12 Thread Paulo Pinto
I hope you will have good arguments when they start speaking about available tooling for C++ vs D. Specially about the all the platforms Crytek supports. "Marco Leise" wrote in message news:op.vzz7f9b29y6...@dslb-088-070-152-209.pools.arcor-ip.net... > Am 10.08.2011, 10:20 Uhr, schrieb Stephan

Re: DB ORM

2011-08-12 Thread kennytm
zhang wrote: >> Graham Fawcett wrote. >>> On Thu, 11 Aug 2011 20:10:15 +0800, zhang wrote: >>> >> I think D needs user defined attributes first. About attribute, here is an example: There is a problem that is D's basic type is not nullable. In C#, th

Re: std.path Accepted 22-0

2011-08-12 Thread Lars T. Kyllingstad
On Fri, 12 Aug 2011 08:45:11 -0400, dsimcha wrote: > Lars Kyllingstad's new std.path has been approved by the D community by > a vote of 22-0. Congratulations, Lars! I look forward to seeing this > in the next release Thanks to all reviewers! I think your feedback had a large, positive impact

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread Simen Kjaeraas
On Fri, 12 Aug 2011 14:55:26 +0200, Marco Leise wrote: Am 12.08.2011, 12:22 Uhr, schrieb kennytm : Don wrote: I've had a look at a dozen or so of these, and they were all real. I didn't see any which require a cast to "make the compiler shut up". That's pretty impressive. In C++ I find tha

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread Jonathan M Davis
On Friday, August 12, 2011 12:39:01 Don wrote: > kennytm wrote: > > Don wrote: > >> I've had a look at a dozen or so of these, and they were all real. I > >> didn't see any which require a cast to "make the compiler shut up". > >> That's pretty impressive. In C++ I find that such messages are near

Re: DIP11

2011-08-12 Thread Jacob Carlborg
On 2011-08-12 15:53, Steven Schveighoffer wrote: This is not true. The compiler implements *hooks* for a download tool. The download tool will be a separate process which turns urls (generated by the compiler) into source files. Once the hooks are implemented, the tool is independent, and we woul

Re: DIP11

2011-08-12 Thread Jacob Carlborg
On 2011-08-12 15:56, Steven Schveighoffer wrote: On Fri, 12 Aug 2011 05:04:13 -0400, Jacob Carlborg wrote: On 2011-08-11 21:36, Steven Schveighoffer wrote: be one-file based, you just need to have a way to map physical packages to module packages. The DIP doesn't explain all this except for

Re: DIP11

2011-08-12 Thread Steven Schveighoffer
On Fri, 12 Aug 2011 12:30:42 -0400, Jacob Carlborg wrote: On 2011-08-12 15:53, Steven Schveighoffer wrote: This is not true. The compiler implements *hooks* for a download tool. The download tool will be a separate process which turns urls (generated by the compiler) into source files. Once th

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread Marco Leise
Am 12.08.2011, 17:48 Uhr, schrieb Simen Kjaeraas : On Fri, 12 Aug 2011 14:55:26 +0200, Marco Leise wrote: Am 12.08.2011, 12:22 Uhr, schrieb kennytm : Don wrote: I've had a look at a dozen or so of these, and they were all real. I didn't see any which require a cast to "make the compile

Re: Next to review: Curl Wrapper? (Was: Review Queue Update?)

2011-08-12 Thread Jimmy Cao
On Fri, Aug 12, 2011 at 7:53 AM, dsimcha wrote: > On 8/10/2011 9:22 AM, dsimcha wrote: > >> The review of the new std.path is drawing to a close and it looks like >> another success! (Congratulations, Lars.) Lately, though, the queue of >> stuff to review has been getting rather long, admittedly

Re: C1X memory-order in C1X

2011-08-12 Thread Sean Kelly
On Aug 12, 2011, at 6:09 AM, bearophile wrote: > I have found this though Reddit, I am not expert about this stuff, but it's > something for the design of the next C (C1X), about memory-order options: > > http://www.open-std.org/JTC1/SC22/WG14/www/docs/n1525.htm This is pretty much what's in C+

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread Walter Bright
On 8/12/2011 8:52 AM, Jonathan M Davis wrote: it's a practice that many people don't seem to follow (in both C/C++ and D), since it's so natural to use int (or auto in D), Back in the olden days of C, it was "best practice" to use int as an index. Times have changed, but old habits die hard.

Re: DIP11

2011-08-12 Thread Jacob Carlborg
On 2011-08-12 15:49, Steven Schveighoffer wrote: Note that the pragmas are specific to that file only. So you don't have an import file which defines pragmas. This is to prevent conflicts between two files that declare the same package override. Now I'm not quite sure I understand. Are you sayi

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread Simen Kjaeraas
On Fri, 12 Aug 2011 19:19:09 +0200, Marco Leise wrote: Am 12.08.2011, 17:48 Uhr, schrieb Simen Kjaeraas : On Fri, 12 Aug 2011 14:55:26 +0200, Marco Leise wrote: Am 12.08.2011, 12:22 Uhr, schrieb kennytm : Don wrote: I've had a look at a dozen or so of these, and they were all real

Re: Any D developer at GDC europe next week ?

2011-08-12 Thread Peter Alexander
On 12/08/11 3:27 PM, Paulo Pinto wrote: I hope you will have good arguments when they start speaking about available tooling for C++ vs D. Specially about the all the platforms Crytek supports. "Marco Leise" wrote in message news:op.vzz7f9b29y6...@dslb-088-070-152-209.pools.arcor-ip.net... A

Re: DIP11

2011-08-12 Thread Jacob Carlborg
On 2011-08-12 16:11, Andrei Alexandrescu wrote: On 8/12/11 3:05 AM, Jacob Carlborg wrote: On 2011-08-11 23:02, Andrei Alexandrescu wrote: It's difficult to get all dependencies when not all sources have been yet downloaded. Andrei No, not when you have a single meta file containing all the d

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread Jacob Carlborg
On 2011-08-12 20:16, Walter Bright wrote: On 8/12/2011 8:52 AM, Jonathan M Davis wrote: it's a practice that many people don't seem to follow (in both C/C++ and D), since it's so natural to use int (or auto in D), Back in the olden days of C, it was "best practice" to use int as an index. Time

Re: DIP11

2011-08-12 Thread Jacob Carlborg
On 2011-08-12 19:08, Steven Schveighoffer wrote: On Fri, 12 Aug 2011 12:30:42 -0400, Jacob Carlborg wrote: On 2011-08-12 15:53, Steven Schveighoffer wrote: This is not true. The compiler implements *hooks* for a download tool. The download tool will be a separate process which turns urls (gen

Re: DIP11

2011-08-12 Thread Steven Schveighoffer
On Fri, 12 Aug 2011 14:24:46 -0400, Jacob Carlborg wrote: On 2011-08-12 15:49, Steven Schveighoffer wrote: Note that the pragmas are specific to that file only. So you don't have an import file which defines pragmas. This is to prevent conflicts between two files that declare the same package

Re: DIP11

2011-08-12 Thread Steven Schveighoffer
On Fri, 12 Aug 2011 14:31:28 -0400, Jacob Carlborg wrote: On 2011-08-12 19:08, Steven Schveighoffer wrote: On Fri, 12 Aug 2011 12:30:42 -0400, Jacob Carlborg wrote: On 2011-08-12 15:53, Steven Schveighoffer wrote: This is not true. The compiler implements *hooks* for a download tool. The d

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread Jacob Carlborg
On 2011-08-12 20:26, Simen Kjaeraas wrote: On Fri, 12 Aug 2011 19:19:09 +0200, Marco Leise wrote: This way it is actually fun to cripple the for loop, yay. Still if people started to argue that it is a bad idea to modify variables in the condition I'd silently agree. So a look at "foreach_rever

Re: Next to review: Curl Wrapper? (Was: Review Queue Update?)

2011-08-12 Thread Jonathan M Davis
On Friday, August 12, 2011 10:48 Jimmy Cao wrote: > On Fri, Aug 12, 2011 at 7:53 AM, dsimcha wrote: > > On 8/10/2011 9:22 AM, dsimcha wrote: > >> The review of the new std.path is drawing to a close and it looks like > >> another success! (Congratulations, Lars.) Lately, though, the queue of > >>

Re: std.path Accepted 22-0

2011-08-12 Thread jdrewsen
Den 12-08-2011 14:45, dsimcha skrev: Lars Kyllingstad's new std.path has been approved by the D community by a vote of 22-0. Congratulations, Lars! I look forward to seeing this in the next release Grats to you Lars. /Jonas

Re: DIP11

2011-08-12 Thread Jacob Carlborg
On 2011-08-12 20:36, Steven Schveighoffer wrote: On Fri, 12 Aug 2011 14:24:46 -0400, Jacob Carlborg wrote: On 2011-08-12 15:49, Steven Schveighoffer wrote: Note that the pragmas are specific to that file only. So you don't have an import file which defines pragmas. This is to prevent conflict

Re: DIP11

2011-08-12 Thread Steven Schveighoffer
On Fri, 12 Aug 2011 15:12:07 -0400, Jacob Carlborg wrote: On 2011-08-12 20:36, Steven Schveighoffer wrote: On Fri, 12 Aug 2011 14:24:46 -0400, Jacob Carlborg wrote: On 2011-08-12 15:49, Steven Schveighoffer wrote: Note that the pragmas are specific to that file only. So you don't have an

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread bearophile
Timon Gehr: > foreach_reverse(i;0..array.length) writeln(array[i]),i--; I'd like to statically forbid some more usages of the comma operator in D :-) Some of them are already forbidden compared to C. This is valid C code: int main() { int array[5]; int i = 1; int j = 2; array[i,

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread Don
Jonathan M Davis wrote: On Friday, August 12, 2011 12:39:01 Don wrote: kennytm wrote: Don wrote: I've had a look at a dozen or so of these, and they were all real. I didn't see any which require a cast to "make the compiler shut up". That's pretty impressive. In C++ I find that such messages

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread Timon Gehr
On 08/12/2011 08:32 PM, Jacob Carlborg wrote: On 2011-08-12 20:16, Walter Bright wrote: On 8/12/2011 8:52 AM, Jonathan M Davis wrote: it's a practice that many people don't seem to follow (in both C/C++ and D), since it's so natural to use int (or auto in D), Back in the olden days of C, it w

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread Timon Gehr
On 08/12/2011 09:32 PM, bearophile wrote: Timon Gehr: foreach_reverse(i;0..array.length) writeln(array[i]),i--; I'd like to statically forbid some more usages of the comma operator in D :-) Some of them are already forbidden compared to C. This is valid C code: int main() { int array[5

Re: DIP11

2011-08-12 Thread Martin Nowak
On Fri, 12 Aug 2011 15:49:30 +0200, Steven Schveighoffer wrote: On Fri, 12 Aug 2011 03:23:30 -0400, Jacob Carlborg wrote: On 2011-08-11 20:31, Steven Schveighoffer wrote: On Thu, 11 Aug 2011 14:19:35 -0400, Jacob Carlborg wrote: So how would that be different if the compiler drives ever

Re: [GSOC] regular expressions beta is here

2011-08-12 Thread bearophile
Don: > bearophile wrote: >> 2) I have found many situations where I am able to solve a problem with both >> a >> simple and slow brute force solver, and a complex and fast algorithm to solve >> a problem. The little program maybe is too much slow for normal usage, but >> it's just few lines long

Do multilanguage application

2011-08-12 Thread bioinfornatics
Dear, I would like to know how do a multilanguage application. It seem it is possible by using flag -J but they are no document for this feature. link givent in this page http://www.digitalmars.com/d/2.0/dmd-linux.html seem to be wrong if you can do a little example, will be nice thanks kind r

Segfault during D1 writefln output of double value

2011-08-12 Thread Jonathan Crapuchettes
I think I've run into a problem with DMD's compilation. Can anyone suggest a work around? In the middle of a function I called writefln to output a double value for testing, but the code is now segfaulting during the execution of writefln. Backtrace from gdb follows. Thanks, JC Program receiv

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread Don
Timon Gehr wrote: On 08/12/2011 09:32 PM, bearophile wrote: Timon Gehr: foreach_reverse(i;0..array.length) writeln(array[i]),i--; I'd like to statically forbid some more usages of the comma operator in D :-) Some of them are already forbidden compared to C. This is valid C code: int main

Re: Segfault during D1 writefln output of double value

2011-08-12 Thread bearophile
Jonathan Crapuchettes: > I think I've run into a problem with DMD's compilation. Can anyone suggest a > work around? In the middle of a function I called writefln to output a double > value for testing, but the code is now segfaulting during the execution of > writefln. Backtrace from gdb follo

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread Walter Bright
On 8/12/2011 11:32 AM, Jacob Carlborg wrote: On 2011-08-12 20:16, Walter Bright wrote: On 8/12/2011 8:52 AM, Jonathan M Davis wrote: it's a practice that many people don't seem to follow (in both C/C++ and D), since it's so natural to use int (or auto in D), Back in the olden days of C, it wa

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread Ellery Newcomer
On 08/12/2011 04:06 PM, Don wrote: No, it was specifically disallowed. Version D 2.037 Dec 3, 2009 New/Changed Features No more comma operators allowed between [ ]. I think that was for type declarations, not index expressions. you can still do this: import std.stdio; struct X{ void opI

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread Simen Kjaeraas
On Fri, 12 Aug 2011 20:36:32 +0200, Jacob Carlborg wrote: On 2011-08-12 20:26, Simen Kjaeraas wrote: On Fri, 12 Aug 2011 19:19:09 +0200, Marco Leise wrote: This way it is actually fun to cripple the for loop, yay. Still if people started to argue that it is a bad idea to modify variables in

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread Timon Gehr
On 08/12/2011 11:06 PM, Don wrote: Timon Gehr wrote: On 08/12/2011 09:32 PM, bearophile wrote: Timon Gehr: foreach_reverse(i;0..array.length) writeln(array[i]),i--; I'd like to statically forbid some more usages of the comma operator in D :-) Some of them are already forbidden compared to

Re: Signed-unsigned comparisons in Phobos

2011-08-12 Thread Timon Gehr
On 08/13/2011 12:37 AM, Ellery Newcomer wrote: On 08/12/2011 04:06 PM, Don wrote: No, it was specifically disallowed. Version D 2.037 Dec 3, 2009 New/Changed Features No more comma operators allowed between [ ]. I think that was for type declarations, not index expressions. you can still do

Thoughts on std.system.OS

2011-08-12 Thread Jonathan M Davis
I made a few changes to std.system to clean it up a bit and make it more thorough: https://github.com/D-Programming-Language/phobos/pull/186 However, on reflection, I'm not convinced that the OS enum and its corresponding os variable along with the os_major and os_minor variables serve any rea

Re: Any D developer at GDC europe next week ?

2011-08-12 Thread Nick Sabalausky
"Peter Alexander" wrote in message news:j23r6m$1nlj$1...@digitalmars.com... > > The conversation wouldn't get to tools. It would end with a simple reply: > "Everyone here knows C++, no one knows D. All our code is written in C++ > and it works." > Any sentence involving the phrases "C++" and "

Re: std.path Accepted 22-0

2011-08-12 Thread Nick Sabalausky
"dsimcha" wrote in message news:j2379q$6fe$1...@digitalmars.com... > Lars Kyllingstad's new std.path has been approved by the D community by a > vote of 22-0. > Geez, Lars, you couldn't have made that module a little less controversial?? :)