Re: Bye bye, fast compilation times

2018-02-08 Thread Stefan Koch via Digitalmars-d
On Wednesday, 7 February 2018 at 22:00:48 UTC, Bastiaan Veelo wrote: On Wednesday, 7 February 2018 at 09:27:47 UTC, Stefan Koch wrote: Another Thing that can be done is reviewing the code and alerting me to potential problems. i.e. Missing or indecipherable comments as well as spelling mistakes

Re: Bye bye, fast compilation times

2018-02-08 Thread Stefan Koch via Digitalmars-d
On Wednesday, 7 February 2018 at 22:00:48 UTC, Bastiaan Veelo wrote: On Wednesday, 7 February 2018 at 09:27:47 UTC, Stefan Koch wrote: Another Thing that can be done is reviewing the code and alerting me to potential problems. i.e. Missing or indecipherable comments as well as spelling mistakes

Re: Status status = __traits(compilesReportError, {string b=10; }) => status.msg=Error: cannot....

2018-02-08 Thread Atila Neves via Digitalmars-d
On Wednesday, 7 February 2018 at 20:29:44 UTC, Timothee Cour wrote: is there any way to get error from speculative execution (`__traits( compiles, ...)`)? would be useful in tests; If not currently how hard would that be to implement? eg: ``` struct Status{bool ok; string msg;} Status status

Re: Heads-up: upcoming instabilities in std.experimental.allocator, and what to do

2018-02-08 Thread Seb via Digitalmars-d
On Friday, 1 December 2017 at 02:30:29 UTC, Seb wrote: On Thursday, 30 November 2017 at 19:01:02 UTC, Andrei Alexandrescu wrote: Hi all, Eduard, Alexandru Jercaianu and I are working on improving allocators' design and implementation. This entails a few breaking changes. In order to make m

Re: missing HexString documentation

2018-02-08 Thread Kagamin via Digitalmars-d
On Wednesday, 7 February 2018 at 17:01:54 UTC, Adam D. Ruppe wrote: http://dpldocs.info/experimental-docs/source/core.sys.posix.fcntl.d.html#L123 version (X86) { enum O_CREAT= 0x40; // octal 0100 enum O_EXCL = 0x80; // octal 0200 enu

Re: missing HexString documentation

2018-02-08 Thread Kagamin via Digitalmars-d
Or have a function specifically for unix permissions, like int unix(int r, int w, int x, int gr, int gw, int gx, int ur, int uw, int ux); It might be even more readable.

A betterC base

2018-02-08 Thread ixid via Digitalmars-d
How difficult would it be for D at this point to move towards a pay for what you use system that out of the box is betterC and requires the garbage collector to be explicitly imported? It feels like D has not overcome at least two major issues in the public mind, the built-in GC and, more ludi

Re: Bye bye, fast compilation times

2018-02-08 Thread Martin Tschierschke via Digitalmars-d
On Monday, 5 February 2018 at 21:27:57 UTC, H. S. Teoh wrote: One of my D projects for the past while has been taking unusually long times to compile. This morning, I finally decided to sit down and figure out exactly why. What I found was rather disturbing: -- import std.regex; void mai

Re: Bye bye, fast compilation times

2018-02-08 Thread H. S. Teoh via Digitalmars-d
On Wed, Feb 07, 2018 at 10:59:51PM -0500, Nick Sabalausky (Abscissa) via Digitalmars-d wrote: [...] > On 02/06/2018 08:47 PM, jmh530 wrote: > > > > Would it help to take the approach of mir, i.e. putting > > version(mir_test) before all the unittests? > > That used to be a very common idiom. (An

Re: A betterC base

2018-02-08 Thread Seb via Digitalmars-d
On Thursday, 8 February 2018 at 11:06:15 UTC, ixid wrote: How difficult would it be for D at this point to move towards a pay for what you use system that out of the box is betterC and requires the garbage collector to be explicitly imported? https://github.com/dlang/druntime/pull/2057 It fee

Re: Heads-up: upcoming instabilities in std.experimental.allocator, and what to do

2018-02-08 Thread Nathan S. via Digitalmars-d
On Thursday, 30 November 2017 at 19:01:02 UTC, Andrei Alexandrescu wrote: So we may switch to ubyte[] Hooray!

Re: A betterC base

2018-02-08 Thread Mike Franklin via Digitalmars-d
On Thursday, 8 February 2018 at 11:06:15 UTC, ixid wrote: How difficult would it be for D at this point to move towards a pay for what you use system that out of the box is betterC and requires the garbage collector to be explicitly imported? I'm not sure if this is what you're looking for, bu

Re: missing HexString documentation

2018-02-08 Thread Steven Schveighoffer via Digitalmars-d
On 2/7/18 3:24 PM, Adam D. Ruppe wrote: On Wednesday, 7 February 2018 at 18:59:38 UTC, Steven Schveighoffer wrote: Not even close. Octal literals are a disaster, because putting a leading 0 should never change the base of a number. I agree the leading 0 is terrible. But that's not the real que

Re: missing HexString documentation

2018-02-08 Thread Steven Schveighoffer via Digitalmars-d
On 2/8/18 1:10 AM, Walter Bright wrote: On 2/7/2018 9:45 PM, Ralph Doncaster wrote: > While the fix is a huge improvement, it doesn't match the code generated by the hex literals.  hexString!"deadbeef" stores the null-terminated string in the data section of the object file, while x"deadbeef"

Re: option -ignore_pure for temporary debugging (or how to wrap an unpure function inside a pure one)?

2018-02-08 Thread Steven Schveighoffer via Digitalmars-d
On 2/7/18 10:32 PM, Timothee Cour wrote: same question with how to wrap a gc function inside a nogc shell, if not, allowing a flag -ignore_nogc that'd enable this (again, for debugging purposes) If you wrap the call in a debug block, it will work. int foo() pure { debug writeln("yep, this w

Re: option -ignore_pure for temporary debugging (or how to wrap an unpure function inside a pure one)?

2018-02-08 Thread Steven Schveighoffer via Digitalmars-d
On 2/8/18 8:32 AM, Steven Schveighoffer wrote: On 2/7/18 10:32 PM, Timothee Cour wrote: same question with how to wrap a gc function inside a nogc shell, if not, allowing a flag -ignore_nogc that'd enable this (again, for debugging purposes) If you wrap the call in a debug block, it will work.

Re: missing HexString documentation

2018-02-08 Thread Adam D. Ruppe via Digitalmars-d
On Thursday, 8 February 2018 at 10:52:35 UTC, Kagamin wrote: Or have a function specifically for unix permissions, like int unix(int r, int w, int x, int gr, int gw, int gx, int ur, int uw, int ux); It might be even more readable. I actually personally prefer binary: 0b_1_111_101_000 which v

Re: missing HexString documentation

2018-02-08 Thread Adam D. Ruppe via Digitalmars-d
On Thursday, 8 February 2018 at 13:06:44 UTC, Steven Schveighoffer wrote: So you think it should go into druntime? I don't see why it wasn't in there in the first place to be honest. Yeah, probably. I might even publically import it when you import the posix header so it just works in the most

Re: A betterC base

2018-02-08 Thread Adam D. Ruppe via Digitalmars-d
On Thursday, 8 February 2018 at 11:06:15 UTC, ixid wrote: It feels like D has not overcome at least two major issues in the public mind, the built-in GC D is a pragmatic language aimed toward writing fast code, fast. Garbage collection has proved to be a smashing success in the industry, prov

Re: A betterC base

2018-02-08 Thread Adam D. Ruppe via Digitalmars-d
ooh better last sentence D's GC implementation follows in the footsteps of industry giants without compromising experts' ability to realize maximum potential from the machine.

Re: missing HexString documentation

2018-02-08 Thread Steven Schveighoffer via Digitalmars-d
On 2/8/18 9:44 AM, Adam D. Ruppe wrote: On Thursday, 8 February 2018 at 13:06:44 UTC, Steven Schveighoffer wrote: So you think it should go into druntime? I don't see why it wasn't in there in the first place to be honest. Yeah, probably. I might even publically import it when you import the

Somewhat OT: defining algebras in D

2018-02-08 Thread Simen Kjærås via Digitalmars-d
So I was bored in a meeting and decided to implement a generic template for defining complex numbers, dual numbers, quaternions and many other possible algebras by simply defining a set of rules and the components on which they act: alias quaternion = Algebra!( float, "1,i,j,k

Re: Quora: Why hasn't D started to replace C++?

2018-02-08 Thread Ralph Doncaster via Digitalmars-d
On Wednesday, 7 February 2018 at 22:31:58 UTC, John Gabriele wrote: I'm not sure how long dub has been around, but having an easy to use CPAN-alike (online module repo) is HUGE. Dub is great for sales. The better dub and the repo gets, the more attractive D gets. I completely agree that the a

Re: A betterC base

2018-02-08 Thread ixid via Digitalmars-d
On Thursday, 8 February 2018 at 14:56:31 UTC, Adam D. Ruppe wrote: ooh better last sentence D's GC implementation follows in the footsteps of industry giants without compromising experts' ability to realize maximum potential from the machine. That's been said over and over and the message h

Re: A betterC base

2018-02-08 Thread Adam D. Ruppe via Digitalmars-d
On Thursday, 8 February 2018 at 15:43:01 UTC, ixid wrote: That's been said over and over and the message has not gotten through. It is almost never said! We always play by their terms and implicitly concede by saying "but we can avoid it" or "look -betterC". Reddit invades our space, and we

Re: A betterC base

2018-02-08 Thread JN via Digitalmars-d
On Thursday, 8 February 2018 at 14:54:19 UTC, Adam D. Ruppe wrote: Garbage collection has proved to be a smashing success in the industry, providing productivity and memory-safety to programmers of all skill levels. Citation needed on how garbage collection has been a smashing success based o

Re: Quora: Why hasn't D started to replace C++?

2018-02-08 Thread Martin Tschierschke via Digitalmars-d
On Thursday, 8 February 2018 at 15:29:08 UTC, Ralph Doncaster wrote: On Wednesday, 7 February 2018 at 22:31:58 UTC, John Gabriele wrote: I'm not sure how long dub has been around, but having an easy to use CPAN-alike (online module repo) is HUGE. Dub is great for sales. The better dub and the r

Re: My choice to pick Go over D ( and Rust ), mostly non-technical

2018-02-08 Thread Nicholas Wilson via Digitalmars-d
On Wednesday, 7 February 2018 at 15:16:46 UTC, Ralph Doncaster wrote: On Wednesday, 7 February 2018 at 15:10:36 UTC, Ralph Doncaster wrote: On Wednesday, 7 February 2018 at 08:05:46 UTC, Nicholas Wilson wrote: For OpenCL I develop and maintain DCompute: http://code.dlang.org/packages/dcompute h

Re: A betterC base

2018-02-08 Thread John Gabriele via Digitalmars-d
On Thursday, 8 February 2018 at 15:51:38 UTC, Adam D. Ruppe wrote: On Thursday, 8 February 2018 at 15:43:01 UTC, ixid wrote: That's been said over and over and the message has not gotten through. It is almost never said! We always play by their terms and implicitly concede by saying "but we c

Re: A betterC base

2018-02-08 Thread Michael via Digitalmars-d
On Thursday, 8 February 2018 at 14:54:19 UTC, Adam D. Ruppe wrote: On Thursday, 8 February 2018 at 11:06:15 UTC, ixid wrote: It feels like D has not overcome at least two major issues in the public mind, the built-in GC D is a pragmatic language aimed toward writing fast code, fast. Garbage c

Re: A betterC base

2018-02-08 Thread Dave Jones via Digitalmars-d
On Thursday, 8 February 2018 at 14:56:31 UTC, Adam D. Ruppe wrote: ooh better last sentence D's GC implementation follows in the footsteps of industry giants without compromising experts' ability to realize maximum potential from the machine. If D had a decent garbage collector it might be

Re: A betterC base

2018-02-08 Thread bachmeier via Digitalmars-d
On Thursday, 8 February 2018 at 17:03:58 UTC, Dave Jones wrote: On Thursday, 8 February 2018 at 14:56:31 UTC, Adam D. Ruppe wrote: ooh better last sentence D's GC implementation follows in the footsteps of industry giants without compromising experts' ability to realize maximum potential fro

Re: A betterC base

2018-02-08 Thread bachmeier via Digitalmars-d
On Thursday, 8 February 2018 at 15:55:09 UTC, JN wrote: Python was also a smashing success, but it doesn't use a garbage collector in it's default implementation (CPython). I'm pretty sure CPython uses a mark-and-sweep GC together with reference counting.

Re: missing HexString documentation

2018-02-08 Thread H. S. Teoh via Digitalmars-d
On Thu, Feb 08, 2018 at 08:26:03AM -0500, Steven Schveighoffer via Digitalmars-d wrote: [...] > The extra data in the object file comes from the inclusion of the > hexStringImpl function, and from the template parameter (the symbol > _D3std4conv__T9hexStringVAyaa8_6465616462656566ZQBiyAa is in the

Re: My choice to pick Go over D ( and Rust ), mostly non-technical

2018-02-08 Thread Ralph Doncaster via Digitalmars-d
On Thursday, 8 February 2018 at 15:59:28 UTC, Nicholas Wilson wrote: On Wednesday, 7 February 2018 at 15:16:46 UTC, Ralph Doncaster wrote: On Wednesday, 7 February 2018 at 15:10:36 UTC, Ralph Doncaster wrote: On Wednesday, 7 February 2018 at 08:05:46 UTC, Nicholas Wilson wrote: For OpenCL I de

Re: missing HexString documentation

2018-02-08 Thread Ralph Doncaster via Digitalmars-d
On Thursday, 8 February 2018 at 17:06:55 UTC, H. S. Teoh wrote: On Thu, Feb 08, 2018 at 08:26:03AM -0500, Steven Schveighoffer via Digitalmars-d wrote: [...] The extra data in the object file comes from the inclusion of the hexStringImpl function, and from the template parameter (the symbol _D

Re: A betterC base

2018-02-08 Thread ixid via Digitalmars-d
On Thursday, 8 February 2018 at 15:51:38 UTC, Adam D. Ruppe wrote: On Thursday, 8 February 2018 at 15:43:01 UTC, ixid wrote: That's been said over and over and the message has not gotten through. It is almost never said! We always play by their terms and implicitly concede by saying "but we c

Re: My choice to pick Go over D ( and Rust ), mostly non-technical

2018-02-08 Thread Nicholas Wilson via Digitalmars-d
On Thursday, 8 February 2018 at 17:24:31 UTC, Ralph Doncaster wrote: On Thursday, 8 February 2018 at 15:59:28 UTC, Nicholas Wilson wrote: On Wednesday, 7 February 2018 at 15:16:46 UTC, Ralph Doncaster wrote: On Wednesday, 7 February 2018 at 15:10:36 UTC, Ralph Doncaster wrote: On Wednesday, 7 F

Re: A betterC base

2018-02-08 Thread Arun Chandrasekaran via Digitalmars-d
On Thursday, 8 February 2018 at 11:40:44 UTC, Seb wrote: On Thursday, 8 February 2018 at 11:06:15 UTC, ixid wrote: [...] https://github.com/dlang/druntime/pull/2057 [...] One of Andrei's student is working on this. I think she has been focusing on templated ==, <= and AAs so far and is no

Re: A betterC base

2018-02-08 Thread Walter Bright via Digitalmars-d
On 2/8/2018 9:03 AM, Dave Jones wrote: If D had a decent garbage collector it might be a more convincing argument. 'Decent' GC systems rely on the compiler emitting "write gates" around every assignment to a pointer. These are justified in languages like Java and Go for which everything is GC

Re: A betterC base

2018-02-08 Thread Walter Bright via Digitalmars-d
On 2/8/2018 7:55 AM, JN wrote: Citation needed on how garbage collection has been a smashing success based on its merits rather than the merits of the languages that use garbage collection. You can't separate the two. The Java and Go language semantics are designed around the GC.

Re: A betterC base

2018-02-08 Thread JN via Digitalmars-d
On Thursday, 8 February 2018 at 18:08:59 UTC, Walter Bright wrote: On 2/8/2018 7:55 AM, JN wrote: Citation needed on how garbage collection has been a smashing success based on its merits rather than the merits of the languages that use garbage collection. You can't separate the two. The Java

Re: missing HexString documentation

2018-02-08 Thread Walter Bright via Digitalmars-d
On 2/8/2018 7:07 AM, Steven Schveighoffer wrote: My concern in the hexString case is the sheer requirement of CTFE for something that is so easy to do in the compiler, already *done* in the compiler, and has another form specifically for hex strings (the "\xde\xad\xbe\xef" form) that isn't goin

Re: missing HexString documentation

2018-02-08 Thread Walter Bright via Digitalmars-d
On 2/8/2018 5:26 AM, Steven Schveighoffer wrote: The extra data in the object file comes from the inclusion of the hexStringImpl function, and from the template parameter (the symbol _D3std4conv__T9hexStringVAyaa8_6465616462656566ZQBiyAa is in there as well, which will always be larger than the

Re: My choice to pick Go over D ( and Rust ), mostly non-technical

2018-02-08 Thread Walter Bright via Digitalmars-d
On 2/6/2018 1:51 AM, Atila Neves wrote: I tried Warp on a non-trivial C codebase. It didn't work (by which I mean the code wouldn't compile with it). I don't know how clang managed to build a (for all practical purposes I can see) bug-compatible preprocessor from scratch to gcc, but it did and

Re: missing HexString documentation

2018-02-08 Thread Ralph Doncaster via Digitalmars-d
On Thursday, 8 February 2018 at 18:31:06 UTC, Walter Bright wrote: On 2/8/2018 5:26 AM, Steven Schveighoffer wrote: The extra data in the object file comes from the inclusion of the hexStringImpl function, and from the template parameter (the symbol _D3std4conv__T9hexStringVAyaa8_6465616462656

Re: missing HexString documentation

2018-02-08 Thread Steven Schveighoffer via Digitalmars-d
On 2/8/18 1:25 PM, Walter Bright wrote: On 2/8/2018 7:07 AM, Steven Schveighoffer wrote: My concern in the hexString case is the sheer requirement of CTFE for something that is so easy to do in the compiler, already *done* in the compiler, and has another form specifically for hex strings (the

Re: missing HexString documentation

2018-02-08 Thread Steven Schveighoffer via Digitalmars-d
On 2/8/18 1:42 PM, Ralph Doncaster wrote: On Thursday, 8 February 2018 at 18:31:06 UTC, Walter Bright wrote: On 2/8/2018 5:26 AM, Steven Schveighoffer wrote: The extra data in the object file comes from the inclusion of the hexStringImpl function, and from the template parameter (the symbol _D

Re: A betterC base

2018-02-08 Thread jmh530 via Digitalmars-d
On Thursday, 8 February 2018 at 18:06:38 UTC, Walter Bright wrote: [snip] More precise GC exacts heavy runtime penalties, too, which is why attempts to add them to D have had mixed results. See, there's your problem right there. Now if you replace the current GC with the slowest possible

Re: missing HexString documentation

2018-02-08 Thread Ralph Doncaster via Digitalmars-d
On Thursday, 8 February 2018 at 18:49:51 UTC, Steven Schveighoffer wrote: I wonder if it's an issue with how obj2asm prints it out? Surely, that data array must be contiguous, and they must be bytes. Otherwise the resulting code would be wrong. OK. I didn't even know about obj2asm until you m

Re: A betterC base

2018-02-08 Thread Jonathan M Davis via Digitalmars-d
On Thursday, February 08, 2018 14:54:19 Adam D. Ruppe via Digitalmars-d wrote: > On Thursday, 8 February 2018 at 11:06:15 UTC, ixid wrote: > > It feels like D has not overcome at least two major issues in > > the public mind, the built-in GC > > D is a pragmatic language aimed toward writing fast

Re: A betterC base

2018-02-08 Thread Walter Bright via Digitalmars-d
On 2/8/2018 10:11 AM, JN wrote: I agree, however these languages would probably have been successful even without GC, using e.g. some form of automatic reference counting. If reference counting would work with Java, and was better, wouldn't the Java developers have done it decades ago?

Re: missing HexString documentation

2018-02-08 Thread Walter Bright via Digitalmars-d
On 2/8/2018 10:49 AM, Steven Schveighoffer wrote: On 2/8/18 1:42 PM, Ralph Doncaster wrote: On Thursday, 8 February 2018 at 18:31:06 UTC, Walter Bright wrote: db    0ffdeh,0ffadh,0ffbeh,0ffefh    ; But it looks like they are all dchar, so 4x the space vs x"deadbeef"?

Re: A betterC base

2018-02-08 Thread H. S. Teoh via Digitalmars-d
On Thu, Feb 08, 2018 at 12:17:06PM -0700, Jonathan M Davis via Digitalmars-d wrote: > On Thursday, February 08, 2018 14:54:19 Adam D. Ruppe via Digitalmars-d > wrote: [...] > > Garbage collection has proved to be a smashing success in the > > industry, providing productivity and memory-safety to

Re: A betterC base

2018-02-08 Thread bachmeier via Digitalmars-d
On Thursday, 8 February 2018 at 19:34:20 UTC, Walter Bright wrote: On 2/8/2018 10:11 AM, JN wrote: I agree, however these languages would probably have been successful even without GC, using e.g. some form of automatic reference counting. If reference counting would work with Java, and was be

Re: A betterC base

2018-02-08 Thread Ola Fosheim Grøstad via Digitalmars-d
On Thursday, 8 February 2018 at 19:51:05 UTC, bachmeier wrote: The developers working on .NET had the opportunity to learn from Java, yet they went with GC.[0] Anyone that says one approach is objectively better than the other is clearly not familiar with all the arguments - or more likely, bel

Re: A betterC base

2018-02-08 Thread Jonathan M Davis via Digitalmars-d
On Thursday, February 08, 2018 11:28:52 H. S. Teoh via Digitalmars-d wrote: > On Thu, Feb 08, 2018 at 12:17:06PM -0700, Jonathan M Davis via Digitalmars-d wrote: > > On Thursday, February 08, 2018 14:54:19 Adam D. Ruppe via Digitalmars-d > > > wrote: > [...] > > > > Garbage collection has proved t

Re: A betterC base

2018-02-08 Thread Paulo Pinto via Digitalmars-d
On Thursday, 8 February 2018 at 18:06:38 UTC, Walter Bright wrote: On 2/8/2018 9:03 AM, Dave Jones wrote: If D had a decent garbage collector it might be a more convincing argument. 'Decent' GC systems rely on the compiler emitting "write gates" around every assignment to a pointer. These are

Re: missing HexString documentation

2018-02-08 Thread Walter Bright via Digitalmars-d
On 2/8/2018 10:42 AM, Steven Schveighoffer wrote: On 2/8/18 1:25 PM, Walter Bright wrote: "abc" is an array (it's an immutable(char)[]). There's no reason why ['a','b','c'] should be different than "abc" (other than the hidden null character, which is irrelevant here). ['a','b','c'] is mutabl

Re: A betterC base

2018-02-08 Thread Walter Bright via Digitalmars-d
On 2/8/2018 11:51 AM, bachmeier wrote: The developers working on .NET had the opportunity to learn from Java, yet they went with GC.[0] Anyone that says one approach is objectively better than the other is clearly not familiar with all the arguments - or more likely, believes their problem is t

Re: Somewhat OT: defining algebras in D

2018-02-08 Thread Amorphorious via Digitalmars-d
On Thursday, 8 February 2018 at 15:23:05 UTC, Simen Kjærås wrote: So I was bored in a meeting and decided to implement a generic template for defining complex numbers, dual numbers, quaternions and many other possible algebras by simply defining a set of rules and the components on which they a

Re: A betterC base

2018-02-08 Thread Adam D. Ruppe via Digitalmars-d
On Thursday, 8 February 2018 at 15:55:09 UTC, JN wrote: Citation needed on how garbage collection has been a smashing success based on its merits rather than the merits of the languages that use garbage collection. Who cares? Even if the success isn't because of GC per se, the ubiquity of it

Re: A betterC base

2018-02-08 Thread Adam D. Ruppe via Digitalmars-d
On Thursday, 8 February 2018 at 16:40:46 UTC, John Gabriele wrote: Regarding what you said about the implementation of the GC following in the footsteps of industry giants, what specifically about D's GC impl is patterned after other industry giant's GC's? The simple fact that it is a GC. The

Re: A betterC base

2018-02-08 Thread Ali via Digitalmars-d
On Thursday, 8 February 2018 at 23:27:25 UTC, Adam D. Ruppe wrote: On Thursday, 8 February 2018 at 15:55:09 UTC, JN wrote: Citation needed on how garbage collection has been a smashing success based on its merits rather than the merits of the languages that use garbage collection. Who cares?

Re: A betterC base

2018-02-08 Thread Rubn via Digitalmars-d
On Thursday, 8 February 2018 at 18:06:38 UTC, Walter Bright wrote: I.e. it isn't an issue of us D guys being dumb about the GC. So you could say it's a design flaw of D, attempting to use a GC where it isn't suited? If going malloc didnt lose you a bunch of features and bring a bunch of oth

Re: A betterC base

2018-02-08 Thread Adam D. Ruppe via Digitalmars-d
On Thursday, 8 February 2018 at 17:32:53 UTC, ixid wrote: Do you really think sticking with the current course on GC would gain more users than very slightly changing tack and making it something you add to a simpler base? I think the second of those will gain more users. No, the current cour

Re: A betterC base

2018-02-08 Thread Adam D. Ruppe via Digitalmars-d
On Thursday, 8 February 2018 at 23:50:29 UTC, Ali wrote: But D, unlike many other languages, promotes itself as primarily a system programming language I think that's a mistake too. I'd rebrand it as a "general purpose" programming language. One language you can use everywhere. It worked for

Re: Bye bye, fast compilation times

2018-02-08 Thread Nick Sabalausky (Abscissa) via Digitalmars-d
On 02/08/2018 06:21 AM, Martin Tschierschke wrote: Beginner question: How to split my project, to compile the regex part separately as a lib and just link them? Unfortunately that depends completely on what buildsystem you're using. But if you're just calling the compiler directly, then it

Re: A betterC base

2018-02-08 Thread Mike Franklin via Digitalmars-d
On Thursday, 8 February 2018 at 17:10:00 UTC, bachmeier wrote: What are D's limitations on do-it-yourself reference counting? * Types that are built into the language like dynamic arrays, associative arrays, and exceptions won't benefit from DIY reference counting. * Much of Phobos probabl

Re: A betterC base

2018-02-08 Thread Mike Franklin via Digitalmars-d
On Friday, 9 February 2018 at 01:31:41 UTC, Mike Franklin wrote: On Thursday, 8 February 2018 at 17:10:00 UTC, bachmeier wrote: What are D's limitations on do-it-yourself reference counting? * Types that are built into the language like dynamic arrays, associative arrays, and exceptions won

Re: A betterC base

2018-02-08 Thread Benny via Digitalmars-d
On Friday, 9 February 2018 at 00:08:56 UTC, Adam D. Ruppe wrote: On Thursday, 8 February 2018 at 23:50:29 UTC, Ali wrote: But D, unlike many other languages, promotes itself as primarily a system programming language I think that's a mistake too. I'd rebrand it as a "general purpose" programm

Re: A betterC base

2018-02-08 Thread Jonathan M Davis via Digitalmars-d
On Thursday, February 08, 2018 23:57:45 Rubn via Digitalmars-d wrote: > On Thursday, 8 February 2018 at 18:06:38 UTC, Walter Bright wrote: > > I.e. it isn't an issue of us D guys being dumb about the GC. > > So you could say it's a design flaw of D, attempting to use a GC > where it isn't suited?

Re: A betterC base

2018-02-08 Thread psychoticRabbit via Digitalmars-d
On Thursday, 8 February 2018 at 15:51:38 UTC, Adam D. Ruppe wrote: On Thursday, 8 February 2018 at 15:43:01 UTC, ixid wrote: That's been said over and over and the message has not gotten through. It is almost never said! We always play by their terms and implicitly concede by saying "but we c

Re: A betterC base

2018-02-08 Thread rjframe via Digitalmars-d
On Thu, 08 Feb 2018 17:08:41 +, bachmeier wrote: > On Thursday, 8 February 2018 at 15:55:09 UTC, JN wrote: > >> Python was also a smashing success, but it doesn't use a garbage >> collector in it's default implementation (CPython). > > I'm pretty sure CPython uses a mark-and-sweep GC togethe

#dbugfix Issue 18068 - No file names and line numbers in stack trace

2018-02-08 Thread Mike Franklin via Digitalmars-d
https://issues.dlang.org/show_bug.cgi?id=18068 I tried to fix this one myself, but it beat me. It's also currently causing me friction when working on DMD. I would love to see it fixed. Interestingly, however, it works fine in the auto-tester. But, problem can be reproduced at https://run.

Re: Somewhat OT: defining algebras in D

2018-02-08 Thread Nick Sabalausky (Abscissa) via Digitalmars-d
On 02/08/2018 04:37 PM, Amorphorious wrote: On Thursday, 8 February 2018 at 15:23:05 UTC, Simen Kjærås wrote: So I was bored in a meeting and decided to implement a generic template for defining complex numbers, dual numbers, quaternions and many other possible algebras by simply defining a set

proposal: heredoc comments to allow `+/` in comments, eg from urls or documented unittests

2018-02-08 Thread Timothee Cour via Digitalmars-d
same exact idea as motivation for delimited strings (https://dlang.org/spec/lex.html#delimited_strings) ``` auto heredoc = q"EOS This is a multi-line heredoc string EOS" ; /"EOC This is a multi-line heredoc comment allowing /+ documented unittests containing nesting comments +/ and weird urls li

Re: #dbugfix Issue 18068 - No file names and line numbers in stack trace

2018-02-08 Thread Mike Parker via Digitalmars-d
On Friday, 9 February 2018 at 02:30:15 UTC, Mike Franklin wrote: https://issues.dlang.org/show_bug.cgi?id=18068 Noted!

Re: proposal: heredoc comments to allow `+/` in comments, eg from urls or documented unittests

2018-02-08 Thread Timothee Cour via Digitalmars-d
NOTE: the analog of documenting comments (/++ ...+/ and /** */) could be: /""EOC multiline comment EOC"/ (ie allow both `/""` and `/"` before reading in the heredoc token) On Thu, Feb 8, 2018 at 7:06 PM, Timothee Cour wrote: > same exact idea as motivation for delimited strings > (https://dlan

Re: A betterC base

2018-02-08 Thread psychoticRabbit via Digitalmars-d
On Friday, 9 February 2018 at 01:55:10 UTC, Benny wrote: People talk about the need for a clear design focus, leadership and ... things go on as before. That is D in a nutshell. People doing what they want, whenever and things stay the same. New features ( that is always fun ), a few people d

Re: #dbugfix Issue 1983

2018-02-08 Thread Mike Parker via Digitalmars-d
On Thursday, 8 February 2018 at 07:26:55 UTC, Mike Franklin wrote: https://issues.dlang.org/show_bug.cgi?id=1983 A PR addressing this issue (https://github.com/dlang/dmd/pull/2130), is the oldest PR in the DMD repository. The issue also is almost a decade old. I'd love to see it finally res

Re: A betterC base

2018-02-08 Thread psychoticRabbit via Digitalmars-d
On Thursday, 8 February 2018 at 23:27:25 UTC, Adam D. Ruppe wrote: On Thursday, 8 February 2018 at 15:55:09 UTC, JN wrote: Citation needed on how garbage collection has been a smashing success based on its merits rather than the merits of the languages that use garbage collection. Who cares?

Re: #dbugfix Issue 18068 - No file names and line numbers in stack trace

2018-02-08 Thread Nick Sabalausky (Abscissa) via Digitalmars-d
Hear, hear! It *used* to work, but doesn't anymore. I may be wrong, but in Linux-land at least I think may be related to PIC. Seemed to work fine until I installed an updated distro that has issues with non-PIC stuff.

Re: proposal: heredoc comments to allow `+/` in comments, eg from urls or documented unittests

2018-02-08 Thread Nick Sabalausky (Abscissa) via Digitalmars-d
On 02/08/2018 10:06 PM, Timothee Cour wrote: /"EOC This is a multi-line heredoc comment allowing /+ documented unittests containing nesting comments +/ That shouldn't be an issue as long as you're using /++ doc comments and not /** ones. If it IS a problem, I'd regard it as a bug. (If I wer

Re: option -ignore_pure for temporary debugging (or how to wrap an unpure function inside a pure one)?

2018-02-08 Thread Timothee Cour via Digitalmars-d
just filed https://issues.dlang.org/show_bug.cgi?id=18407 Issue 18407 - debug should escape nothrow, @nogc, @safe (not just pure) On Thu, Feb 8, 2018 at 5:38 AM, Steven Schveighoffer via Digitalmars-d wrote: > On 2/8/18 8:32 AM, Steven Schveighoffer wrote: >> >> On 2/7/18 10:32 PM, Timothee Cour

Re: A betterC base

2018-02-08 Thread Suliman via Digitalmars-d
- import ... really, we are 2018 and people are still wasting our time to have standard libraries as imports. Its even more fun when you split, only to need import the array library. Please explain what do you mean by it?

Which language futures make D overcompicated?

2018-02-08 Thread Suliman via Digitalmars-d
I like D, but sometimes it's look like for me too complicated. Go have a lot of fans even it not simple, but primitive. But some D futures make it very hard to learning. Small list by me: 1. mixins 2. inout 3. too many attributes like: @safe @system @nogc etc Which language futures by your opi