Re: gl3n does not seem to have an ortho function like glm. Any replacements?

2015-10-04 Thread WhatMeWorry via Digitalmars-d-learn
On Monday, 5 October 2015 at 00:05:42 UTC, Rene Zwanenburg wrote: On Sunday, 4 October 2015 at 21:30:43 UTC, WhatMeWorry wrote: I'm porting some C++/OpenGL/glm code over to D, And I've run into a glm::ortho function. glm::mat4 projection = glm::ortho(0.0f, static_cast(WIDTH), 0.0f,

Re: __simd_sto confusion

2015-10-04 Thread Benjamin Thaut via Digitalmars-d-learn
On Saturday, 3 October 2015 at 14:47:02 UTC, Nachtraaf wrote: I'm trying to create some linear algebra functions using simd intrinsics. I watched the dconf 2013 presentation by Manu Evans but i'm still confused about some aspects and the following piece of code doesn't work. I'm trying to copy

Re: Threading Questions

2015-10-04 Thread bitwise via Digitalmars-d-learn
On Wednesday, 30 September 2015 at 10:32:01 UTC, Jonathan M Davis wrote: On Tuesday, September 29, 2015 22:38:42 Johannes Pfau via Digitalmars-d-learn wrote: [...] What I took from the answers to that SO question was that in general, it really doesn't matter whether a condition variable has

Re: How to break gdb on D exception ?

2015-10-04 Thread BBasile via Digitalmars-d-learn
On Friday, 2 October 2015 at 09:15:13 UTC, Dmitri wrote: On Friday, 2 October 2015 at 04:50:59 UTC, BBasile wrote: On Friday, 2 October 2015 at 04:46:51 UTC, BBasile wrote: On Friday, 2 October 2015 at 04:24:11 UTC, Adam D. Ruppe wrote: On Friday, 2 October 2015 at 03:58:45 UTC, BBasile

std.functional:partial - disambiguating templated functions

2015-10-04 Thread Laeeth Isharc via Digitalmars-d-learn
How do I persuade partial to tie itself to the appropriate overload? I have: alias bars=partial!(slurpBars!BarType,filename,startDate,endDate); where there are two overloads of slurpBars: SomeBar[] slurpBars(SomeBar)(string filename,string datasetName, typeof(SomeBar.date) startDate,

Re: std.functional:partial - disambiguating templated functions

2015-10-04 Thread John Colvin via Digitalmars-d-learn
On Sunday, 4 October 2015 at 15:45:55 UTC, Laeeth Isharc wrote: How do I persuade partial to tie itself to the appropriate overload? I have: alias bars=partial!(slurpBars!BarType,filename,startDate,endDate); where there are two overloads of slurpBars: SomeBar[] slurpBars(SomeBar)(string

Re: std.functional:partial - disambiguating templated functions

2015-10-04 Thread Laeeth Isharc via Digitalmars-d-learn
On Sunday, 4 October 2015 at 16:37:34 UTC, John Colvin wrote: On Sunday, 4 October 2015 at 15:45:55 UTC, Laeeth Isharc wrote: How do I persuade partial to tie itself to the appropriate overload? --- As far as I can see std.functional.partial only does one argument at a time.

Concatenation of ubyte[] to char[] works, but assignation doesn't

2015-10-04 Thread skilion via Digitalmars-d-learn
Is this allowed by the language or it is a compiler bug ? void main() { char[] a = "abc".dup; ubyte[] b = [1, 2, 3]; a = b; // cannot implicitly convert expression (b) of type ubyte[] to char[] a ~= b; // works }

Re: std.functional:partial - disambiguating templated functions

2015-10-04 Thread Laeeth Isharc via Digitalmars-d-learn
On Sunday, 4 October 2015 at 16:37:34 UTC, John Colvin wrote: On Sunday, 4 October 2015 at 15:45:55 UTC, Laeeth Isharc wrote: How do I persuade partial to tie itself to the appropriate overload? I have: alias bars=partial!(slurpBars!BarType,filename,startDate,endDate); where there are two

Re: Threading Questions

2015-10-04 Thread bitwise via Digitalmars-d-learn
On Tuesday, 29 September 2015 at 23:20:31 UTC, Steven Schveighoffer wrote: yeah, that could probably be done. One thing to note is that these classes are from ages ago (probably close to 10 years). New API suggestions may be allowed. -Steve I'm still thinking about my last rant, here...

Re: __simd_sto confusion

2015-10-04 Thread Nachtraaf via Digitalmars-d-learn
That's a shame. I've read that each compiler has his own quirks and not support everything dmd supports. I do want to keep the code as portable as possible. Guess I'll try using inline assembler and runtime checks for the right cpu architecture. Thanks for the help people.

Re: std.functional:partial - disambiguating templated functions

2015-10-04 Thread Laeeth Isharc via Digitalmars-d-learn
On Sunday, 4 October 2015 at 18:24:08 UTC, John Colvin wrote: On Sunday, 4 October 2015 at 18:08:55 UTC, Laeeth Isharc wrote: On Sunday, 4 October 2015 at 17:17:14 UTC, Laeeth Isharc wrote: On Sunday, 4 October 2015 at 16:37:34 UTC, John Colvin wrote: On Sunday, 4 October 2015 at 15:45:55 UTC,

Re: std.functional:partial - disambiguating templated functions

2015-10-04 Thread John Colvin via Digitalmars-d-learn
On Sunday, 4 October 2015 at 19:12:51 UTC, Laeeth Isharc wrote: On Sunday, 4 October 2015 at 18:24:08 UTC, John Colvin wrote: On Sunday, 4 October 2015 at 18:08:55 UTC, Laeeth Isharc wrote: On Sunday, 4 October 2015 at 17:17:14 UTC, Laeeth Isharc wrote: On Sunday, 4 October 2015 at 16:37:34

Re: std.functional:partial - disambiguating templated functions

2015-10-04 Thread Laeeth Isharc via Digitalmars-d-learn
On Sunday, 4 October 2015 at 17:17:14 UTC, Laeeth Isharc wrote: On Sunday, 4 October 2015 at 16:37:34 UTC, John Colvin wrote: On Sunday, 4 October 2015 at 15:45:55 UTC, Laeeth Isharc wrote: How do I persuade partial to tie itself to the appropriate overload? --- As far as I can see

Re: std.functional:partial - disambiguating templated functions

2015-10-04 Thread John Colvin via Digitalmars-d-learn
On Sunday, 4 October 2015 at 20:26:51 UTC, John Colvin wrote: template bish(T) { alias tmp = bish0!T; alias tmp = bish1!T; alias bish = tmp; } https://issues.dlang.org/show_bug.cgi?id=15156

Re: std.functional:partial - disambiguating templated functions

2015-10-04 Thread Laeeth Isharc via Digitalmars-d-learn
On Sunday, 4 October 2015 at 20:34:53 UTC, John Colvin wrote: On Sunday, 4 October 2015 at 20:26:51 UTC, John Colvin wrote: template bish(T) { alias tmp = bish0!T; alias tmp = bish1!T; alias bish = tmp; } https://issues.dlang.org/show_bug.cgi?id=15156 Thanks very

Re: std.functional:partial - disambiguating templated functions

2015-10-04 Thread John Colvin via Digitalmars-d-learn
On Sunday, 4 October 2015 at 18:08:55 UTC, Laeeth Isharc wrote: On Sunday, 4 October 2015 at 17:17:14 UTC, Laeeth Isharc wrote: On Sunday, 4 October 2015 at 16:37:34 UTC, John Colvin wrote: On Sunday, 4 October 2015 at 15:45:55 UTC, Laeeth Isharc wrote: How do I persuade partial to tie itself

Re: buffered output to files

2015-10-04 Thread Gerald Jansen via Digitalmars-d-learn
On Saturday, 3 October 2015 at 22:21:08 UTC, Gerald Jansen wrote: My simple test program is here: http://dpaste.dzfl.pl/329023e651c4. An alternative link to the program (that doesn't try to run it) http://codepad.org/FbHJJqYM.

gl3n does not seem to have an ortho function like glm. Any replacements?

2015-10-04 Thread WhatMeWorry via Digitalmars-d-learn
I'm porting some C++/OpenGL/glm code over to D, And I've run into a glm::ortho function. glm::mat4 projection = glm::ortho(0.0f, static_cast(WIDTH), 0.0f, static_cast (HEIGHT)); gl3n is great for vecs and mats but does not appear to have an ortho function. Any suggestions? Thanks in

Re: Concatenation of ubyte[] to char[] works, but assignation doesn't

2015-10-04 Thread Jonathan M Davis via Digitalmars-d-learn
On Sunday, October 04, 2015 16:13:47 skilion via Digitalmars-d-learn wrote: > Is this allowed by the language or it is a compiler bug ? > > void main() { > char[] a = "abc".dup; > ubyte[] b = [1, 2, 3]; > a = b; // cannot implicitly convert expression (b) of type > ubyte[] to char[]

Re: gl3n does not seem to have an ortho function like glm. Any replacements?

2015-10-04 Thread Rene Zwanenburg via Digitalmars-d-learn
On Sunday, 4 October 2015 at 21:30:43 UTC, WhatMeWorry wrote: I'm porting some C++/OpenGL/glm code over to D, And I've run into a glm::ortho function. glm::mat4 projection = glm::ortho(0.0f, static_cast(WIDTH), 0.0f, static_cast (HEIGHT)); gl3n is great for vecs and mats but does not

Re: Threading Questions

2015-10-04 Thread Jonathan M Davis via Digitalmars-d-learn
On Sunday, October 04, 2015 14:42:48 bitwise via Digitalmars-d-learn wrote: > Since D is moving towards a phobos with no GC, what will happen > to things that are classes like Condition and Mutex? Phobos and druntime will always use the GC for some things, and some things just plain need classes.

Re: How to break gdb on D exception ?

2015-10-04 Thread BBasile via Digitalmars-d-learn
On Sunday, 4 October 2015 at 14:31:43 UTC, BBasile wrote: On Friday, 2 October 2015 at 09:15:13 UTC, Dmitri wrote: On Friday, 2 October 2015 at 04:50:59 UTC, BBasile wrote: On Friday, 2 October 2015 at 04:46:51 UTC, BBasile wrote: On Friday, 2 October 2015 at 04:24:11 UTC, Adam D. Ruppe