Re: Installing DUB on OSX

2016-02-23 Thread Jacob Carlborg via Digitalmars-d-learn
On 2016-02-24 07:49, Joel wrote: I get this: Joels-MacBook-Pro:bin joelcnz$ ln -s /usr/local/bin/dub /usr/bin ln: /usr/bin/dub: Operation not permitted Joels-MacBook-Pro:bin joelcnz$ If you have OS X 10.10.x or lower you can prefix the command with "sudo". If you have OS X 10.11 or later you

Re: Installing DUB on OSX

2016-02-23 Thread Joel via Digitalmars-d-learn
On Saturday, 20 February 2016 at 12:01:04 UTC, Jacob Carlborg wrote: On 2016-02-20 04:21, Joel wrote: How do you do symbolic links? ln -s Replace and with the appropriate paths. I get this: Joels-MacBook-Pro:bin joelcnz$ ln -s /usr/local/bin/dub /usr/bin ln: /usr/bin/dub: Operation no

Re: vk.xml

2016-02-23 Thread Mike Parker via Digitalmars-d-learn
On Wednesday, 24 February 2016 at 00:50:40 UTC, Nicholas Wilson wrote: AA's are nice in theory but the non-deterministic nature of their order of iteration is painful... An ordered map as the default AA implementation would be worse. Most use cases for a hash map don't need ordering. Perhaps

Re: Simple performance question from a newcomer

2016-02-23 Thread Mike Parker via Digitalmars-d-learn
On Tuesday, 23 February 2016 at 20:03:30 UTC, dextorious wrote: For instance, I am still not sure how to make it pass the -O5 switch to the LDC2 compiler and the impression I got from the documentation is that explicit manual switches can only be supplied for the DMD compiler. If you're refer

Re: vk.xml

2016-02-23 Thread Nicholas Wilson via Digitalmars-d-learn
On Sunday, 21 February 2016 at 15:18:44 UTC, ZombineDev wrote: On Sunday, 21 February 2016 at 12:52:33 UTC, Nicholas Wilson wrote: [...] I'm glad to see more people looking to create a D binding from vk.xml! I was also working on this (http://forum.dlang.org/post/ygylvtuwwiwyqtcnl...@forum.d

Re: Starting threads inside class

2016-02-23 Thread Ali Çehreli via Digitalmars-d-learn
On 02/23/2016 07:31 AM, Josh wrote: > My goal with the code below is to eventually have my main communicate > with Foo and Bar classes listening for packets on a different > address/port, each in a separate thread. The main issue is that in D all data is thread-local by-default. main() cannot cr

Re: Issues

2016-02-23 Thread Andre via Digitalmars-d-learn
On Tuesday, 23 February 2016 at 19:53:52 UTC, Johan Engelen wrote: On Monday, 22 February 2016 at 23:21:28 UTC, Jonathan M Davis wrote: Well, if you'll notice th list of resolved issues is going up way faster than the list of new issues. (To put some oil on the fire:) But the number of new

Re: Simple performance question from a newcomer

2016-02-23 Thread jmh530 via Digitalmars-d-learn
On Tuesday, 23 February 2016 at 20:03:30 UTC, dextorious wrote: Personally, I think a few aspects of documentation for the various compilers, dub and possibly the dlang.org website itself could be improved, if accessibility is considered important. Couldn't agree more. Being new to the l

Re: Simple performance question from a newcomer

2016-02-23 Thread dextorious via Digitalmars-d-learn
On Tuesday, 23 February 2016 at 14:07:22 UTC, Marc Schütz wrote: On Tuesday, 23 February 2016 at 11:10:40 UTC, ixid wrote: We really need to standard algorithms to be fast and perhaps have separate ones for perfect technical accuracy. While I agree with most of what you're saying, I don't th

Re: Simple performance question from a newcomer

2016-02-23 Thread dextorious via Digitalmars-d-learn
On Tuesday, 23 February 2016 at 11:10:40 UTC, ixid wrote: On Monday, 22 February 2016 at 15:43:23 UTC, dextorious wrote: I do have to wonder, however, about the default settings of dub in this case. Having gone through its documentation, I might still not have guessed to try the compiler option

Re: Issues

2016-02-23 Thread Johan Engelen via Digitalmars-d-learn
On Monday, 22 February 2016 at 23:21:28 UTC, Jonathan M Davis wrote: Well, if you'll notice th list of resolved issues is going up way faster than the list of new issues. (To put some oil on the fire:) But the number of new issues /is/ going up. I.e. the number of resolved issues is going

Re: Issues

2016-02-23 Thread H. S. Teoh via Digitalmars-d-learn
On Tue, Feb 23, 2016 at 02:38:42PM +, Andre via Digitalmars-d-learn wrote: [...] > In case of #4763 I closed it because 2 out of 3 enhancement requests > were fixed/solved and the 3rd was open for about 5 years, without > recent activity, no owner, empty CC and no votes. [...] Sometimes people

Re: Simple performance question from a newcomer

2016-02-23 Thread ixid via Digitalmars-d-learn
On Tuesday, 23 February 2016 at 14:07:22 UTC, Marc Schütz wrote: On Tuesday, 23 February 2016 at 11:10:40 UTC, ixid wrote: We really need to standard algorithms to be fast and perhaps have separate ones for perfect technical accuracy. While I agree with most of what you're saying, I don't th

Starting threads inside class

2016-02-23 Thread Josh via Digitalmars-d-learn
My goal with the code below is to eventually have my main communicate with Foo and Bar classes listening for packets on a different address/port, each in a separate thread. They would then communicate with Foobaz and Barbaz threads respectively to do other work. In trying to get just Foo workin

Re: Issues

2016-02-23 Thread Andre via Digitalmars-d-learn
On Tuesday, 23 February 2016 at 00:13:23 UTC, ag0aep6g wrote: On 22.02.2016 23:56, Andre wrote: I was wondering how people in this D community think about the number of issues with NEW status... It could scare individuals/organizations to start with D, when they get the impression that there

Re: Simple performance question from a newcomer

2016-02-23 Thread bachmeier via Digitalmars-d-learn
On Tuesday, 23 February 2016 at 11:10:40 UTC, ixid wrote: On Monday, 22 February 2016 at 15:43:23 UTC, dextorious wrote: I do have to wonder, however, about the default settings of dub in this case. Having gone through its documentation, I might still not have guessed to try the compiler option

Re: arsd.dom getElementsByTagNameChildrenOnly?

2016-02-23 Thread Adam D. Ruppe via Digitalmars-d-learn
On Tuesday, 23 February 2016 at 11:10:17 UTC, Nicholas Wilson wrote: How do I iterate over the child level elements only (ignoring the ones like VkStructureType)? Element.childNodes gives only direct children. You could also do document.querySelectorAll("types > type") to get only the tags

Re: call to super trashes pointer?

2016-02-23 Thread Steven Schveighoffer via Digitalmars-d-learn
On 2/23/16 6:05 AM, Nicholas Wilson wrote: On Tuesday, 23 February 2016 at 10:47:17 UTC, Rene Zwanenburg wrote: On Tuesday, 23 February 2016 at 09:16:08 UTC, Nicholas Wilson wrote: struct A { int blah; } class B { A* a; this(A* _a) { writeln(_a) a =_a; } } class

Re: Simple performance question from a newcomer

2016-02-23 Thread Marc Schütz via Digitalmars-d-learn
On Tuesday, 23 February 2016 at 11:10:40 UTC, ixid wrote: We really need to standard algorithms to be fast and perhaps have separate ones for perfect technical accuracy. While I agree with most of what you're saying, I don't think we should prioritize performance over accuracy or correctness

Re: constant expression

2016-02-23 Thread Steven Schveighoffer via Digitalmars-d-learn
On 2/23/16 3:00 AM, Nicholas Wilson wrote: On Tuesday, 23 February 2016 at 07:43:37 UTC, Ali Çehreli wrote: On 02/22/2016 11:38 PM, Nicholas Wilson wrote: I've tried with both mutable and immutable a module scope. Scope I want is global (don't care about mutability) Uncomment immutable if y

Re: dub dustmite: Initial test fails

2016-02-23 Thread Vladimir Panteleev via Digitalmars-d-learn
On Tuesday, 23 February 2016 at 11:09:00 UTC, denizzzka wrote: Hi! I have a code with segfault. I decided to try to take advantage with dub dustmite: $ dub dustmite ~/ssd/pgator_dustmite0 --program-status=139 -- --config=my_pgator.conf --debug=true Shells process signal exit codes in a spe

Re: SIGSEGV when using D DLL with Qt MinGW

2016-02-23 Thread Jerry via Digitalmars-d-learn
On Tuesday, 23 February 2016 at 11:10:30 UTC, Mike Parker wrote: I'm surprised you're able to get an executable when linking with the import library. I actually just tried a bunch of extern(?), extern "?" combinations and it compiled. If you want 32-bit COFF output from DMD, you'll need to

Re: SIGSEGV when using D DLL with Qt MinGW

2016-02-23 Thread Mike Parker via Digitalmars-d-learn
On Tuesday, 23 February 2016 at 08:50:45 UTC, Jerry wrote: I am using the following environment: Windows 7 Qt 5.5 MinGW 4.9 DMD 2.69.1 DUB (with dynamicLibrary option) Everything is x86. I am really stuck here. Thanks on beforehand. I'm surprised you're able to get an executable when linkin

Re: Simple performance question from a newcomer

2016-02-23 Thread ixid via Digitalmars-d-learn
On Monday, 22 February 2016 at 15:43:23 UTC, dextorious wrote: I do have to wonder, however, about the default settings of dub in this case. Having gone through its documentation, I might still not have guessed to try the compiler options you provided, thereby losing out on a 2-3x performance i

arsd.dom getElementsByTagNameChildrenOnly?

2016-02-23 Thread Nicholas Wilson via Digitalmars-d-learn
So the vulkan spec has a lot of stuff like VkStructureType sType const void* pNext optional="true">VkBufferCreateFlags flags VkDeviceSize

dub dustmite: Initial test fails

2016-02-23 Thread denizzzka via Digitalmars-d-learn
Hi! I have a code with segfault. I decided to try to take advantage with dub dustmite: $ dub dustmite ~/ssd/pgator_dustmite0 --program-status=139 -- --config=my_pgator.conf --debug=true WARNING: A deprecated branch based version specification is used for the dependency vibe-d-postgresql. Ple

Re: call to super trashes pointer?

2016-02-23 Thread Nicholas Wilson via Digitalmars-d-learn
On Tuesday, 23 February 2016 at 10:47:17 UTC, Rene Zwanenburg wrote: On Tuesday, 23 February 2016 at 09:16:08 UTC, Nicholas Wilson wrote: struct A { int blah; } class B { A* a; this(A* _a) { writeln(_a) a =_a; } } class C : B { this(A* _a) { write

Re: call to super trashes pointer?

2016-02-23 Thread Rene Zwanenburg via Digitalmars-d-learn
On Tuesday, 23 February 2016 at 09:16:08 UTC, Nicholas Wilson wrote: struct A { int blah; } class B { A* a; this(A* _a) { writeln(_a) a =_a; } } class C : B { this(A* _a) { writeln(_a) super(_a); } } int main(string[] args) { A

Re: call to super trashes pointer?

2016-02-23 Thread Nicholas Wilson via Digitalmars-d-learn
On Tuesday, 23 February 2016 at 09:16:08 UTC, Nicholas Wilson wrote: struct A { int blah; } class B { A* a; this(A* _a) { writeln(_a) a =_a; } } class C : B { this(A* _a) { writeln(_a) super(_a); } } int main(string[] args) { A

call to super trashes pointer?

2016-02-23 Thread Nicholas Wilson via Digitalmars-d-learn
struct A { int blah; } class B { A* a; this(A* _a) { writeln(_a) a =_a; } } class C : B { this(A* _a) { writeln(_a) super(_a); } } int main(string[] args) { A a; writeln(&a); C c = new C(&a); } prints 7FFF56E787F

SIGSEGV when using D DLL with Qt MinGW

2016-02-23 Thread Jerry via Digitalmars-d-learn
Hello guys, as the title says I'm getting a SIGSEGV when trying to use a D DLL. Let's take a look on this C++ code: extern "C" __declspec(dllimport) void D_user_fillEngine(const char* workDir, void* engine); extern "C" __declspec(dllimport) int D_user_startUp(); extern "C" __declspec(dllimpo

Re: constant expression

2016-02-23 Thread Nicholas Wilson via Digitalmars-d-learn
On Tuesday, 23 February 2016 at 07:43:37 UTC, Ali Çehreli wrote: On 02/22/2016 11:38 PM, Nicholas Wilson wrote: I've tried with both mutable and immutable a module scope. Scope I want is global (don't care about mutability) Uncomment immutable if you want immutable and remove 'shared' if y