Re: Replace/Rename DWT forum with GUIs forum?

2016-09-21 Thread Vadim Lopatin via Digitalmars-d
On Sunday, 18 September 2016 at 23:21:26 UTC, Gerald wrote: I would like to suggest that the existing DWT forum be renamed or replaced with a more generic GUIs forum. As far as I can tell, the DWT forum doesn't get much traffic these days and I don't believe any of the current GUI options for

[Issue 16524] New: Use Shared C Runtime on Windows

2016-09-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16524 Issue ID: 16524 Summary: Use Shared C Runtime on Windows Product: D Version: D2 Hardware: All URL: http://dlang.org/ OS: All Status: NEW

Re: Argumnentation against external function operator overloading is unconvincing

2016-09-21 Thread HaraldZealot via Digitalmars-d
On Wednesday, 21 September 2016 at 21:14:15 UTC, H. S. Teoh wrote: Thank you both, I see now. So it seems to be essential point. But because we already have the same problem with UFCS, I don't see why we should prohibit external overloading of operator, it is just inequality (in political

Re: How to get a screenshot?

2016-09-21 Thread Konstantin Kutsevalov via Digitalmars-d-learn
On Wednesday, 21 September 2016 at 16:36:32 UTC, Adam D. Ruppe wrote: On Wednesday, 21 September 2016 at 16:33:58 UTC, Konstantin Kutsevalov wrote: do anybody know how to get screenshot (for now in Linux only)? May be some library , examples? simplest might be to just call out to

Re: Module Clarification

2016-09-21 Thread tcak via Digitalmars-d-learn
On Wednesday, 21 September 2016 at 14:17:56 UTC, Jonathan Marler wrote: I'm working on a code generation tool and wanted to make sure my module approach was correct. The generated code has a module hierarchy, where modules can appear at any level of the hierarchy. module foo; module

Vibe.d help

2016-09-21 Thread Gestalt Theory via Digitalmars-d-learn
1. I get this error when trying to run a project in VS. dub doesn't give the error. First-chance exception: core.exception.AssertError free() called with null array. at vibe-d-0.7.26\source\vibe\utils\memory.d(110) It constantly pops up then I get an access violation and crash. 2. Many

Re: Stacktrace on Null Pointer Derefence

2016-09-21 Thread Jonathan Marler via Digitalmars-d-learn
On Wednesday, 21 September 2016 at 23:36:08 UTC, Nordlöw wrote: Doing a null deref such as int* y = null; *y = 42;// boom [...] Can you include compiler command line? I use -g -gs -debug to get stack traces on windows.

Re: Stacktrace on Null Pointer Derefence

2016-09-21 Thread ketmar via Digitalmars-d-learn
On Wednesday, 21 September 2016 at 23:36:08 UTC, Nordlöw wrote: Is there a way to get a stacktrace instead? { import etc.linux.memoryerror; registerMemoryErrorHandler(); } warning: this is hightly system-specific, and may work or not work depending of the moon phase, and may broke on any

[Issue 16523] [ICE] Internal error: backend/symbol.c 1031

2016-09-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16523 --- Comment #7 from uplink.co...@googlemail.com --- (In reply to Martin Krejcirik from comment #6) > (In reply to uplink.coder from comment #3) > > > > I think allowing non-static cases is going to be a bugfest, down the road > > and we should think

Re: topN using a heap

2016-09-21 Thread Andrei Alexandrescu via Digitalmars-d
On 09/21/2016 01:37 PM, Jon Degenhardt wrote: On Wednesday, 21 September 2016 at 14:58:27 UTC, Andrei Alexandrescu wrote: On 9/21/16 4:16 AM, Jon Degenhardt wrote: Timing comparison of sort and topN, times in milliseconds: sort topN Field 2: 289 1756 Field 3: 285

Re: Cppcon tonight at 8:30 in Bellevue

2016-09-21 Thread Walter Bright via Digitalmars-d-announce
On 9/21/2016 3:48 PM, Brad Anderson wrote: On Wednesday, 21 September 2016 at 22:32:27 UTC, Walter Bright wrote: Wednesday 09/21/2016 8:30pm: Writing Secure C++ CppCon is being hosted at the Meydenbauer Center in Bellevue. Directions and parking information can be found here:

Stacktrace on Null Pointer Derefence

2016-09-21 Thread Nordlöw via Digitalmars-d-learn
Doing a null deref such as int* y = null; *y = 42;// boom currently outputs /home/per/.emacs.d/auto-builds/dmd/Debug-Unittest-Require-Full-Coverage/home/per/foo[0x406474] /lib/x86_64-linux-gnu/libpthread.so.0(+0x113d0)[0x7f08cf25e3d0]

[Issue 16523] [ICE] Internal error: backend/symbol.c 1031

2016-09-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16523 Martin Krejcirik changed: What|Removed |Added CC||m...@krej.cz --

[Issue 16523] [ICE] Internal error: backend/symbol.c 1031

2016-09-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16523 --- Comment #6 from Martin Krejcirik --- (In reply to uplink.coder from comment #3) > > I think allowing non-static cases is going to be a bugfest, down the road > and we should think hard about this behavior. Declaration of a

[Issue 16523] [ICE] Internal error: backend/symbol.c 1031

2016-09-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16523 David Nadlinger changed: What|Removed |Added Keywords||ice-on-invalid-code

[Issue 16523] [ICE] Internal error: backend/symbol.c 1031

2016-09-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16523 uplink.co...@googlemail.com changed: What|Removed |Added Status|NEW |RESOLVED

[Issue 15938] ctor doesn't initialize fields when struct is static immutable

2016-09-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=15938 John Colvin changed: What|Removed |Added CC|

Re: Cppcon tonight at 8:30 in Bellevue

2016-09-21 Thread Brad Anderson via Digitalmars-d-announce
On Wednesday, 21 September 2016 at 22:32:27 UTC, Walter Bright wrote: Wednesday 09/21/2016 8:30pm: Writing Secure C++ CppCon is being hosted at the Meydenbauer Center in Bellevue. Directions and parking information can be found here: http://www.meydenbauer.com/parking-directions/ Additional

Cppcon tonight at 8:30 in Bellevue

2016-09-21 Thread Walter Bright via Digitalmars-d-announce
Wednesday 09/21/2016 8:30pm: Writing Secure C++ CppCon is being hosted at the Meydenbauer Center in Bellevue. Directions and parking information can be found here: http://www.meydenbauer.com/parking-directions/ Additional information on CppCon can be found here: http://cppcon.org/ Don't

[Issue 16523] [ICE] Internal error: backend/symbol.c 1031

2016-09-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16523 uplink.co...@googlemail.com changed: What|Removed |Added CC||uplink.co...@googlemail.com

[Issue 16523] [ICE] Internal error: backend/symbol.c 1031

2016-09-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16523 --- Comment #1 from b2.t...@gmx.com --- The culprit is the local variable, as shown by this reduction void main() { int i; switch(i) { int j; case j:{} default: break; } } which produces the same error. --

[Issue 16523] New: [ICE] Internal error: backend/symbol.c 1031

2016-09-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16523 Issue ID: 16523 Summary: [ICE] Internal error: backend/symbol.c 1031 Product: D Version: D2 Hardware: x86_64 OS: Linux Status: NEW Severity: critical

Re: Vibe.d compilation error: backend/cgelem.c 5018 dmd failed with exit code 1.

2016-09-21 Thread Rene Zwanenburg via Digitalmars-d-learn
On Wednesday, 21 September 2016 at 20:22:42 UTC, llaine wrote: The project is pretty big, DustMite would handle this? Yes, but it may take some time. For large projects, running it on a server is advisable. 3K LOC should be doable on a desktop machine. Dub has built-in support for running

[Issue 15938] ctor doesn't initialize fields when struct is static immutable

2016-09-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=15938 ag0ae...@gmail.com changed: What|Removed |Added Keywords||wrong-code CC|

Re: Argumnentation against external function operator overloading is unconvincing

2016-09-21 Thread H. S. Teoh via Digitalmars-d
On Wed, Sep 21, 2016 at 08:53:06PM +, HaraldZealot via Digitalmars-d wrote: > On Wednesday, 21 September 2016 at 19:01:40 UTC, Timon Gehr wrote: > > > > Basically, the rationale is: external operators cannot be used in > > generic code that does not import the module defining the operators. >

Anybody fix Issue 15938

2016-09-21 Thread Temtaime via Digitalmars-d
https://issues.dlang.org/show_bug.cgi?id=15938 It's very annoying. It forces me to create a shared static ctor's and then i get cyclic dependency runtime errors. Thanks if anybody can make something with it.

Re: Argumnentation against external function operator overloading is unconvincing

2016-09-21 Thread Timon Gehr via Digitalmars-d
On 21.09.2016 22:53, HaraldZealot wrote: On Wednesday, 21 September 2016 at 19:01:40 UTC, Timon Gehr wrote: Basically, the rationale is: external operators cannot be used in generic code that does not import the module defining the operators. Could you give some elaborate example, for now I

Re: The removal of inactive forum groups

2016-09-21 Thread Iain Buclaw via Digitalmars-d
On 21 September 2016 at 21:43, Dennis Ritchie via Digitalmars-d wrote: > I also want to add that GDC's forum has turned into some kind of bugtracker > :D > We must somehow share it, for example, at GDC General and GDC Bugtracker. Good thing that when people usually

[Issue 16522] opIndex broken for single-length Only ranges

2016-09-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16522 Mathias Lang changed: What|Removed |Added Status|NEW |RESOLVED

[Issue 16521] Wrong code generation with switch + static foreach

2016-09-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16521 --- Comment #1 from Mathias Lang --- A bit of debugging proved that the following code is generated: ``` [{ enum ulong idx = 0; uint unused = _param_1; case idx: { assert(unused == args[idx], "Borken compiler"); break

Re: Argumnentation against external function operator overloading is unconvincing

2016-09-21 Thread HaraldZealot via Digitalmars-d
On Wednesday, 21 September 2016 at 19:01:40 UTC, Timon Gehr wrote: Basically, the rationale is: external operators cannot be used in generic code that does not import the module defining the operators. Could you give some elaborate example, for now I can't imagine what your mean.

[Issue 16522] New: opIndex broken for single-length Only ranges

2016-09-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16522 Issue ID: 16522 Summary: opIndex broken for single-length Only ranges Product: D Version: D2 Hardware: x86_64 OS: Windows Status: NEW Severity: enhancement

[Issue 16519] toHexString always returns stack allocated string

2016-09-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16519 Steven Schveighoffer changed: What|Removed |Added CC|

[Issue 12625] implicit slicing of RValue static array should be illegal

2016-09-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=12625 Steven Schveighoffer changed: What|Removed |Added See Also|

Re: Vibe.d compilation error: backend/cgelem.c 5018 dmd failed with exit code 1.

2016-09-21 Thread llaine via Digitalmars-d-learn
On Wednesday, 21 September 2016 at 15:24:08 UTC, Saurabh Das wrote: On Wednesday, 21 September 2016 at 14:15:30 UTC, llaine wrote: I'm sure some more experienced forum readers will weigh in soon, but my understanding is that: All ICEs are errors in the compiler. You should submit it as a bug

Re: Question about __treats

2016-09-21 Thread Steven Schveighoffer via Digitalmars-d-learn
On 9/21/16 3:38 AM, Suliman wrote: On Wednesday, 21 September 2016 at 07:09:01 UTC, rikki cattermole wrote: On 21/09/2016 7:06 PM, Suliman wrote: It's seems that __treats is language keyword that help to get info from compile-time. But there is also lib named std.traits and I can't understand

Falcor Router in D

2016-09-21 Thread Robert burner Schadek via Digitalmars-d
Is anybody working on a falcor-router [1] written in D? [1] https://github.com/Netflix/falcor

[Issue 16507] std.experimental.allocator: FreeTree clears too eagerly

2016-09-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16507 Ryan changed: What|Removed |Added CC|

[Issue 16521] New: Wrong code generation with switch + static foreach

2016-09-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16521 Issue ID: 16521 Summary: Wrong code generation with switch + static foreach Product: D Version: D2 Hardware: x86_64 OS: Linux Status: NEW Severity: major

Re: Argumnentation against external function operator overloading is unconvincing

2016-09-21 Thread jmh530 via Digitalmars-d
On Wednesday, 21 September 2016 at 19:01:40 UTC, Timon Gehr wrote: Basically, the rationale is: external operators cannot be used in generic code that does not import the module defining the operators. So why not have the struct/class explicitly import external operators? You can do this

Re: The removal of inactive forum groups

2016-09-21 Thread Dennis Ritchie via Digitalmars-d
I also want to add that GDC's forum has turned into some kind of bugtracker :D We must somehow share it, for example, at GDC General and GDC Bugtracker.

[Issue 16520] New: static foreach should be more explicit

2016-09-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16520 Issue ID: 16520 Summary: static foreach should be more explicit Product: D Version: D2 Hardware: All OS: All Status: NEW Severity: enhancement

Re: Why I am switching to Go

2016-09-21 Thread jmh530 via Digitalmars-d
On Wednesday, 21 September 2016 at 18:00:14 UTC, Chris wrote: tldr; vibe.d helps you to set up web servers, but you have to know web related stuff too - or be willing to learn it as you go along. It's not straight out of the box. The tutorials page is not the prettiest page in the world.

Re: Argumnentation against external function operator overloading is unconvincing

2016-09-21 Thread Timon Gehr via Digitalmars-d
On 21.09.2016 21:01, Timon Gehr wrote: On 21.09.2016 19:57, HaraldZealot wrote: So if someone has real rationale not to have operator overloading as external function I'm curios to arguments. [1] http://dlang.org/rationale.html There is no technical reason that would make the

Re: [OT] my 10 minute talk about template-slowness

2016-09-21 Thread Stefan Koch via Digitalmars-d
On Wednesday, 21 September 2016 at 18:34:13 UTC, Michael Coulombe wrote: On Wednesday, 21 September 2016 at 17:14:34 UTC, Stefan Koch wrote: That can and is being fixed. Templates can only be fixed partially and I am not even sure of that. I am not suggesting to remove templates. I just want

Re: Argumnentation against external function operator overloading is unconvincing

2016-09-21 Thread Timon Gehr via Digitalmars-d
On 21.09.2016 19:57, HaraldZealot wrote: So if someone has real rationale not to have operator overloading as external function I'm curios to arguments. [1] http://dlang.org/rationale.html There is no technical reason that would make the implementation of this feature difficult, if that

Re: Argumnentation against external function operator overloading is unconvincing

2016-09-21 Thread Ilya Yaroshenko via Digitalmars-d
On Wednesday, 21 September 2016 at 17:57:17 UTC, HaraldZealot wrote: In current D, overloading operator like "+" with external function is prohibited. There is the rationale [1] (see second paragraph). [...] I am completely agree. We should support external operator overloading for ndslice

Re: thisExePath purity

2016-09-21 Thread Steven Schveighoffer via Digitalmars-d-learn
On 9/20/16 3:42 PM, crimaniak wrote: On Tuesday, 20 September 2016 at 13:35:27 UTC, Steven Schveighoffer wrote: Note that if you don't import the module that contains the static ctor, it should be trimmed by the linker. Let's imagine linker can trim even imported module with static ctor, if

Re: [OT] my 10 minute talk about template-slowness

2016-09-21 Thread Michael Coulombe via Digitalmars-d
On Wednesday, 21 September 2016 at 17:14:34 UTC, Stefan Koch wrote: That can and is being fixed. Templates can only be fixed partially and I am not even sure of that. I am not suggesting to remove templates. I just want to raise awareness that they have a rather high cost. CTFE performance

Re: Why I am switching to Go

2016-09-21 Thread Chris via Digitalmars-d
On Wednesday, 21 September 2016 at 17:22:26 UTC, bachmeier wrote: I agree, but it is easier to learn those things if you're using a different language, due to the assumption with vibe.d that you've got that background. Yeah, I think that's the basic problem with people's expectations of

Argumnentation against external function operator overloading is unconvincing

2016-09-21 Thread HaraldZealot via Digitalmars-d
In current D, overloading operator like "+" with external function is prohibited. There is the rationale [1] (see second paragraph). BUT this rationale is totally UNCONVINCING. I can say that resume of rationale is: "it is impossible because it brakes some C++ patterns and behaviour".

Re: Why I am switching to Go

2016-09-21 Thread Karabuta via Digitalmars-d
On Wednesday, 21 September 2016 at 16:13:13 UTC, bachmeier wrote: On Wednesday, 21 September 2016 at 13:56:01 UTC, Nick Sabalausky wrote: On 09/20/2016 03:14 PM, Intersteller wrote: Vibe.d looks great on the surface but lack of documentation, http://vibed.org/docs http://vibed.org/api

Re: Using Libraries

2016-09-21 Thread Karabuta via Digitalmars-d-learn
On Wednesday, 21 September 2016 at 16:23:35 UTC, Darren wrote: Also I've been making a bit of a mess in dub apparently. I'm getting: Locally registered package gl3n ~master was not found. Please run "dub remove-local C:\Users\Darren\D stuff\opengl\lib". whenever dub gets used. Then if I

Re: topN using a heap

2016-09-21 Thread Jon Degenhardt via Digitalmars-d
On Wednesday, 21 September 2016 at 14:58:27 UTC, Andrei Alexandrescu wrote: On 9/21/16 4:16 AM, Jon Degenhardt wrote: Timing comparison of sort and topN, times in milliseconds: sort topN Field 2: 289 1756 Field 3: 285148793 Field 4: 273668906 The above times

[Issue 7835] switch case fallthrough error despite a break inside static foreach

2016-09-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=7835 Mathias Lang changed: What|Removed |Added Status|REOPENED|RESOLVED

Re: Why I am switching to Go

2016-09-21 Thread bachmeier via Digitalmars-d
On Wednesday, 21 September 2016 at 17:05:41 UTC, Chris wrote: found out that it's not vibe.d's lack of documentation, but how servers work that is the biggest obstacle. Once you know how certain things work, it's no longer so hard find out how to do it with vibe.d, e.g. when and how to set

[Issue 14887] break in static foreach should apply to outer scope

2016-09-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=14887 Mathias Lang changed: What|Removed |Added CC|

Re: [OT] my 10 minute talk about template-slowness

2016-09-21 Thread Stefan Koch via Digitalmars-d
On Wednesday, 21 September 2016 at 16:11:04 UTC, WebFreak001 wrote: Interesting talk. Templates are indeed slow but the reason why I use them over CTFE functions (or why i leave out ctfe in general and just use functions) is that they don't require 20 GB of RAM for some medium-simple tasks

Re: Why I am switching to Go

2016-09-21 Thread Chris via Digitalmars-d
On Wednesday, 21 September 2016 at 16:13:13 UTC, bachmeier wrote: To someone like me, who has done little web development, that documentation isn't very helpful. I have copies of both D Web Development and Learning D (which includes a nice example) and *that* got me going. Overall, there are

Re: How to get a screenshot?

2016-09-21 Thread Adam D. Ruppe via Digitalmars-d-learn
On Wednesday, 21 September 2016 at 16:33:58 UTC, Konstantin Kutsevalov wrote: do anybody know how to get screenshot (for now in Linux only)? May be some library , examples? simplest might be to just call out to `shellExec("import -window root filename.png");` and it will write the file.

[Issue 16423] ModuleInfo missing when linking to static lib with classes

2016-09-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16423 --- Comment #6 from Jacob Carlborg --- (In reply to Steven Schveighoffer from comment #5) > In fact, I actually TRY your suggestion to solve the original problem and it > doesn't work. See the PR: >

How to get a screenshot?

2016-09-21 Thread Konstantin Kutsevalov via Digitalmars-d-learn
Hello everyone, do anybody know how to get screenshot (for now in Linux only)? May be some library , examples?

[Issue 8681] dmd accepts mutable AA key types for objects

2016-09-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=8681 Marco Leise changed: What|Removed |Added CC||marco.le...@gmx.de ---

Re: Why I am switching to Go

2016-09-21 Thread bachmeier via Digitalmars-d
On Wednesday, 21 September 2016 at 13:56:01 UTC, Nick Sabalausky wrote: On 09/20/2016 03:14 PM, Intersteller wrote: Vibe.d looks great on the surface but lack of documentation, http://vibed.org/docs http://vibed.org/api There's also two examples right on the homepage. Did you try

Re: [OT] my 10 minute talk about template-slowness

2016-09-21 Thread WebFreak001 via Digitalmars-d
On Wednesday, 21 September 2016 at 14:32:25 UTC, Stefan Koch wrote: Hi, I just recorded a draft for a talk about templates and why they are slow. I'd be interested in questions and improvement suggestions. I have uploaded it here : http://www96.zippyshare.com/v/dlNhyACZ/file.html

Re: Why I am switching to Go

2016-09-21 Thread Chris via Digitalmars-d
On Wednesday, 21 September 2016 at 13:56:01 UTC, Nick Sabalausky wrote: On 09/20/2016 03:14 PM, Intersteller wrote: Vibe.d looks great on the surface but lack of documentation, http://vibed.org/docs http://vibed.org/api There's also two examples right on the homepage. Did you try

Re: Vibe.d compilation error: backend/cgelem.c 5018 dmd failed with exit code 1.

2016-09-21 Thread Saurabh Das via Digitalmars-d-learn
On Wednesday, 21 September 2016 at 14:15:30 UTC, llaine wrote: Using dmd every day and since one day I'm getting this error when I'm compiling using the -b release flag (dub build -b release). I'm compiling a vibe.d application that has roughly 3k LoC. Removing the -b flag solves the

[Issue 16423] ModuleInfo missing when linking to static lib with classes

2016-09-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16423 Steven Schveighoffer changed: What|Removed |Added Status|RESOLVED|REOPENED

Re: topN using a heap

2016-09-21 Thread Andrei Alexandrescu via Digitalmars-d
On 9/21/16 4:16 AM, Jon Degenhardt wrote: Timing comparison of sort and topN, times in milliseconds: sort topN Field 2: 289 1756 Field 3: 285148793 Field 4: 273668906 The above times are for LDC 1.1.0-beta2 (DMD 2.071.1). Similar behavior is seen for DMD

Re: SQLite-D goes beta!

2016-09-21 Thread yawniek via Digitalmars-d-announce
On Tuesday, 20 September 2016 at 20:37:33 UTC, Stefan Koch wrote: On Tuesday, 20 September 2016 at 20:34:19 UTC, Karabuta wrote: Great work! Can't wait to see sample code :) It's in app.d also see test.d very elegant! congrats!

Re: Custom test runner

2016-09-21 Thread Nick Sabalausky via Digitalmars-d-learn
On 09/21/2016 02:26 AM, Jacob Carlborg wrote: On 2016-09-21 07:51, Nick Sabalausky wrote: IIRC, there is some way to hook in and use a custom unittest-runner. How does one go about that? http://dlang.org/phobos/core_runtime.html#.Runtime.moduleUnitTester Cool, thanks. I got that to work,

[OT] my 10 minute talk about template-slowness

2016-09-21 Thread Stefan Koch via Digitalmars-d
Hi, I just recorded a draft for a talk about templates and why they are slow. I'd be interested in questions and improvement suggestions. I have uploaded it here : http://www96.zippyshare.com/v/dlNhyACZ/file.html

Re: Why I am switching to Go

2016-09-21 Thread dom via Digitalmars-d
14 months ago i tried to write my first webapp. initially i chose vibe.d to be my framework. i got a simple app running quickly, but due to my lack of knowledge about webapps in general i got stuck at rather fundamental things. like doing authentication over oauth, or even have a rough

Module Clarification

2016-09-21 Thread Jonathan Marler via Digitalmars-d-learn
I'm working on a code generation tool and wanted to make sure my module approach was correct. The generated code has a module hierarchy, where modules can appear at any level of the hierarchy. module foo; module foo.bar; In this case, module foo and foo.bar are independent modules. The foo

Re: Why I am switching to Go

2016-09-21 Thread Chris Wright via Digitalmars-d
On Wed, 21 Sep 2016 09:56:01 -0400, Nick Sabalausky wrote: > Not to be a dick, but you really didn't look *at all*, did you? You *are* being a dick. Please stop it. When someone takes the time to post something like this, they are reporting the pain they experienced. They might not articulate

Vibe.d compilation error: backend/cgelem.c 5018 dmd failed with exit code 1.

2016-09-21 Thread llaine via Digitalmars-d-learn
Using dmd every day and since one day I'm getting this error when I'm compiling using the -b release flag (dub build -b release). I'm compiling a vibe.d application that has roughly 3k LoC. Removing the -b flag solves the problem. Dmd version : v2.071.0 Vibe.d version : 0.7.26

Re: Why I am switching to Go

2016-09-21 Thread Dejan Lekic via Digitalmars-d
...I could care less why you are switching to Go...

Re: null analysis with control flow

2016-09-21 Thread Nick Sabalausky via Digitalmars-d
On 09/21/2016 09:10 AM, w0rp wrote: 1. Most languages (including D) do not support pattern matching. If pattern matching was added, it would be totally alien to any programmers coming from C, Java, JavaScript, Python, etc. This means this method of handling null might not be adopted. I've

Re: Why I am switching to Go

2016-09-21 Thread Nick Sabalausky via Digitalmars-d
On 09/20/2016 03:14 PM, Intersteller wrote: Vibe.d looks great on the surface but lack of documentation, http://vibed.org/docs http://vibed.org/api There's also two examples right on the homepage. Did you try scrolling? I'll grant that the stupid "modern" sales-pitch-first,

Re: What is the best way to store bitarray (blob) for pasting in database?

2016-09-21 Thread Vadim Lopatin via Digitalmars-d-learn
On Wednesday, 6 April 2016 at 12:56:39 UTC, Suliman wrote: I have next task. There is PostgreSQL DB. With field like: id, mydata. mydata - is binary blob. It can be 10MB or even more. I need load all data from PostgreSQL to SQLLite. I decided ti create struct that and fill it with data. And

Re: PostgreSQL. Unknown parameter of configuration : "autocommit"

2016-09-21 Thread Vadim Lopatin via Digitalmars-d-learn
On Tuesday, 5 April 2016 at 07:53:20 UTC, Suliman wrote: Is there anybody who have success connect to PostgreSQL with ddbc? I am getting next error: https://github.com/buggins/ddbc/issues/22 Fixed.

Re: [OT] Brokerage for the D Language Foundation

2016-09-21 Thread Andrea Fontana via Digitalmars-d
On Sunday, 18 September 2016 at 11:16:47 UTC, Mark wrote: [...] I think you can make 1-2% a year without taking a lot of risk, e.g. by investing in investment-grade corporate bonds with short maturity. [...] Or buying some coca-cola shares.

Re: null analysis with control flow

2016-09-21 Thread jmh530 via Digitalmars-d
On Wednesday, 21 September 2016 at 13:10:53 UTC, w0rp wrote: 1. Most languages (including D) do not support pattern matching. If pattern matching was added, it would be totally alien to any programmers coming from C, Java, JavaScript, Python, etc. This means this method of handling null

Re: Using Libraries

2016-09-21 Thread Darren via Digitalmars-d-learn
On Tuesday, 20 September 2016 at 19:45:57 UTC, Karabuta wrote: On Tuesday, 20 September 2016 at 15:38:55 UTC, Darren wrote: On Tuesday, 20 September 2016 at 15:07:53 UTC, rikki cattermole wrote: Ok lets start at the very beginning... I think I need to start before that, haha. I might need

Re: [OT] Brokerage for the D Language Foundation

2016-09-21 Thread jmh530 via Digitalmars-d
On Sunday, 18 September 2016 at 16:13:55 UTC, Andrei Alexandrescu wrote: The basic idea here is to have a buffer for short-term borrowing. For example, for DConf we'd need to plop down some money for renting a conference hall until proceeds from registration roll in. The notion of being able

Re: null analysis with control flow

2016-09-21 Thread eugene via Digitalmars-d
On Wednesday, 21 September 2016 at 13:10:53 UTC, w0rp wrote: Assignment of null to a type T is forbidden. Assignment to a type T? forms a fence, which would imply an atomic fence. When a type T is assigned to a variable of type T?, then after that line of code, the value can be considered to

null analysis with control flow

2016-09-21 Thread w0rp via Digitalmars-d
null references. We hate them, they make our programs exit in circumstances we didn't anticipate. Tony Hoare called them a "billion dollar mistake." I've spoken about this issue in this forum before, others have, we know this issue well. TypeScript 2 and Swift, and some Java IDEs, implement a

Re: Template overloads involving `string` and `char[constant]` return value

2016-09-21 Thread Adam D. Ruppe via Digitalmars-d-learn
On Wednesday, 21 September 2016 at 12:39:57 UTC, Johan Engelen wrote: It should really be mentioned in the documentation of toHexString, with an actual example instead of a unittest. Do you use my dpldocs.info? I add such notes there from time to time:

Re: Template overloads involving `string` and `char[constant]` return value

2016-09-21 Thread Johan Engelen via Digitalmars-d-learn
On Wednesday, 21 September 2016 at 13:06:08 UTC, Adam D. Ruppe wrote: the variable you are assigning the result to never does anything with regard to overloads or template args. Gotcha, thanks.

[Issue 16519] toHexString always returns stack allocated string

2016-09-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16519 Johan Engelen changed: What|Removed |Added Severity|major |normal --- Comment

Re: Template overloads involving `string` and `char[constant]` return value

2016-09-21 Thread Adam D. Ruppe via Digitalmars-d-learn
On Wednesday, 21 September 2016 at 12:29:54 UTC, Johan Engelen wrote: Wouldn't something like this be possible? `T toHexString(string toHexString(Order order = Order.increasing, LetterCase letterCase = LetterCase.upper, T)(.) if (T == string)` I'm not sure what that's supposed to

Re: Implement the "unum" representation in D ?

2016-09-21 Thread Andrea Fontana via Digitalmars-d
On Wednesday, 21 September 2016 at 10:25:39 UTC, Nick B wrote: On Wednesday, 21 September 2016 at 07:52:18 UTC, Ethan Watson wrote: On Tuesday, 20 September 2016 at 22:52:57 UTC, Nic Brummell Is there some central repository with links to the active projects? I'll try and wrap my head fully

Allocating Heap/GC Storage upon Default Construction of RC Containers

2016-09-21 Thread Nordlöw via Digitalmars-d-learn
Is there any way to make a default constructor of a struct container allocate/initialize an internal pointer? I need this in a container with RC behaviour similar to struct Container { this()// this is currently forbidden: { _rcStore =

Re: Template overloads involving `string` and `char[constant]` return value

2016-09-21 Thread Johan Engelen via Digitalmars-d-learn
On Wednesday, 21 September 2016 at 12:20:14 UTC, Adam D. Ruppe wrote: This is a pretty common pitfall (and IMO one of the most egregious design flaws in the language), I see it all the time. I write very little D code, so I guess it had to happen at some point then. Man, this is really bad

Re: Template overloads involving `string` and `char[constant]` return value

2016-09-21 Thread Johan Engelen via Digitalmars-d-learn
On Wednesday, 21 September 2016 at 12:20:14 UTC, Adam D. Ruppe wrote: It is neither, the compiler chose the right overload (remember, overloads are chosen based on the arguments alone, the type you specify for the variable holding the return value isn't a consideration there) and the

Re: Template overloads involving `string` and `char[constant]` return value

2016-09-21 Thread Adam D. Ruppe via Digitalmars-d-learn
On Wednesday, 21 September 2016 at 12:07:31 UTC, Johan Engelen wrote: string a = toHexString(hash); This is a pretty common pitfall (and IMO one of the most egregious design flaws in the language), I see it all the time. toHexString, when given a static array, returns a static array,

Template overloads involving `string` and `char[constant]` return value

2016-09-21 Thread Johan Engelen via Digitalmars-d-learn
What's the bug in the following code: ```d import std.digest.md; import std.stdio; pragma(inline, false) // just in case string getHash() { ubyte[16] hash = [1,2,3,4,5,6,6,78,8,8,7,7,6,3,2,3]; string a = toHexString(hash); return a; } pragma(inline, false) // just in case void

[Issue 16519] New: toHexString always returns stack allocated string

2016-09-21 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16519 Issue ID: 16519 Summary: toHexString always returns stack allocated string Product: D Version: D2 Hardware: All OS: All Status: NEW Severity: major

Re: Error: no property 'select' for type 'ddbc.core.Statement'

2016-09-21 Thread Vadim Lopatin via Digitalmars-d-learn
On Sunday, 31 January 2016 at 09:15:04 UTC, Suliman wrote: I hope that here I will get answer faster then on https://github.com/buggins/ddbc/issues/18 I am using ddbc diver for access to mysql. I need to return result of request to struct. My code is next: import std.stdio; import ddbc.all;

Re: D and math, can you isolate this ?

2016-09-21 Thread Basile B. via Digitalmars-d-learn
On Tuesday, 20 September 2016 at 12:35:18 UTC, Basile B. wrote: The problem is here: https://github.com/BBasile/iz/blob/master/import/iz/math.d#L849 - f(x,c) = 1.0 - pow(1.0 - pow(x, 2.0/c), c * 0.5); - c(f0.5)) = ? Which means that I ask you if you can isolate c for y = 1.0 - pow(1.0 -

  1   2   >