Re: requests module generates " Can't parse uri '' "

2019-11-08 Thread cartland via Digitalmars-d-learn
On Saturday, 9 November 2019 at 00:53:13 UTC, cartland wrote: On Friday, 8 November 2019 at 17:01:07 UTC, ikod wrote: *snip* Even this does it. import requests; void main() { } https://github.com/ikod/dlang-requests/issues/109

Re: requests module generates " Can't parse uri '' "

2019-11-08 Thread cartland via Digitalmars-d-learn
On Friday, 8 November 2019 at 17:01:07 UTC, ikod wrote: On Friday, 8 November 2019 at 03:29:41 UTC, cartland wrote: First time D use :) After dub init, I used the example from https://code.dlang.org/packages/requests and ran "dub add requests" [...] If you still stuck with this problem,

I need "duic.cpp" already compiled for .exe for convert .ui files to .d for Dlang

2019-11-08 Thread Marcone via Digitalmars-d-learn
Hi, I'm at the beginning of Dlang studies. I want to create a graphical interface for my program. I use Qt Designer to draw the GUI and save to .ui file. Could someone send me the file "duic.exe" which converts .ui files into .d for Dlang? I need the "duic.cpp" already compiled for .exe. I

Re: How decode encoded Base64 to string text?

2019-11-08 Thread Marcone via Digitalmars-d-learn
On Friday, 8 November 2019 at 12:36:37 UTC, Aldo wrote: On Friday, 8 November 2019 at 11:46:44 UTC, Marcone wrote: I can encode "Helo World!" to Base64 and get "TWFyY29uZQ==", but if I try to decode "TWFyY29uZQ==" I can not recovery "Helo World!" but [77, 97, 114, 99, 111, 110, 101]. How can I

Re: Default initialization of static array faster than void initialization

2019-11-08 Thread kinke via Digitalmars-d-learn
On Friday, 8 November 2019 at 16:49:37 UTC, wolframw wrote: I compiled with dmd -O -inline -release -noboundscheck -mcpu=avx2 and ran the tests with the m array being default-initialized in one run and void-initialized in another run. The results: Default-initialized: 245 ms, 495 μs, and 2

Re: Default initialization of static array faster than void initialization

2019-11-08 Thread Ali Çehreli via Digitalmars-d-learn
One correction: I think you mean "using" a default-initialized array is faster (not the initialization itself). Another observation: dmd -O makes both cases slower! Hm? Ali

Re: requests module generates " Can't parse uri '' "

2019-11-08 Thread ikod via Digitalmars-d-learn
On Friday, 8 November 2019 at 03:29:41 UTC, cartland wrote: First time D use :) After dub init, I used the example from https://code.dlang.org/packages/requests and ran "dub add requests" [...] If you still stuck with this problem, you can post new issue on github project page, I'll try

Default initialization of static array faster than void initialization

2019-11-08 Thread wolframw via Digitalmars-d-learn
Hi, Chapter 12.15.2 of the spec explains that void initialization of a static array can be faster than default initialization. This seems logical because the array entries don't need to be set to NaN. However, when I ran some tests for my matrix implementation, it seemed that the

Re: Using an async buffer

2019-11-08 Thread bioinfornatics via Digitalmars-d-learn
On Friday, 8 November 2019 at 14:32:25 UTC, bioinfornatics wrote: On Friday, 8 November 2019 at 08:58:36 UTC, bioinfornatics wrote: [...] I do not have found yet why the line counter is false. I can tell if the amount to read imply that the last read is not not strictly equal to the buffer

Re: is the runtime implemented in betterC?

2019-11-08 Thread Adam D. Ruppe via Digitalmars-d-learn
On Friday, 8 November 2019 at 15:25:40 UTC, dangbinghoo wrote: hmm, if runtime is implemented in regular D, how could the regular D code depends on regular D runtime be compiled when we doesn't have a D runtime even exists? Think of a file like this: // test.d void foo() { } void bar() {

Re: is the runtime implemented in betterC?

2019-11-08 Thread dangbinghoo via Digitalmars-d-learn
On Friday, 8 November 2019 at 13:52:18 UTC, kinke wrote: On Friday, 8 November 2019 at 10:40:15 UTC, dangbinghoo wrote: hi, I'm not sure what you are trying to achieve; you can easily cross-compile druntime & Phobos with LDC, see https://wiki.dlang.org/Building_LDC_runtime_libraries. hmm,

Re: Using an async buffer

2019-11-08 Thread bioinfornatics via Digitalmars-d-learn
On Friday, 8 November 2019 at 08:58:36 UTC, bioinfornatics wrote: the error message was understandable to me, ... the error message was not understandable to me ... I do not have found yet why the line counter is false. I can tell if the amount to read imply that the last read is not not

Re: is the runtime implemented in betterC?

2019-11-08 Thread kinke via Digitalmars-d-learn
On Friday, 8 November 2019 at 10:40:15 UTC, dangbinghoo wrote: hi, is the runtime d code implemented purely with betterC? i was thinking that what's happening when we building ARM dlang compiler, when the dlang compiler ready in the first, there's no ARM version of the runtime lib and

Re: is the runtime implemented in betterC?

2019-11-08 Thread Adam D. Ruppe via Digitalmars-d-learn
On Friday, 8 November 2019 at 10:40:15 UTC, dangbinghoo wrote: is the runtime d code implemented purely with betterC? It is actually implemented in regular D! i was thinking that what's happening when we building ARM dlang compiler, when the dlang compiler ready in the first, there's no ARM

Re: How decode encoded Base64 to string text?

2019-11-08 Thread Simen Kjærås via Digitalmars-d-learn
On Friday, 8 November 2019 at 11:46:44 UTC, Marcone wrote: I can encode "Helo World!" to Base64 and get "TWFyY29uZQ==", but if I try to decode "TWFyY29uZQ==" I can not recovery "Helo World!" but [77, 97, 114, 99, 111, 110, 101]. How can I recover "Helo World!" when decode? Thank you. import

Re: How decode encoded Base64 to string text?

2019-11-08 Thread Aldo via Digitalmars-d-learn
On Friday, 8 November 2019 at 11:46:44 UTC, Marcone wrote: I can encode "Helo World!" to Base64 and get "TWFyY29uZQ==", but if I try to decode "TWFyY29uZQ==" I can not recovery "Helo World!" but [77, 97, 114, 99, 111, 110, 101]. How can I recover "Helo World!" when decode? Thank you. ...

How decode encoded Base64 to string text?

2019-11-08 Thread Marcone via Digitalmars-d-learn
I can encode "Helo World!" to Base64 and get "TWFyY29uZQ==", but if I try to decode "TWFyY29uZQ==" I can not recovery "Helo World!" but [77, 97, 114, 99, 111, 110, 101]. How can I recover "Helo World!" when decode? Thank you. import std; void main(){ string text = "Helo World!";

Blog Post #86: Nodes-n-noodles, Part V - The Drawing Routines

2019-11-08 Thread Ron Tarrant via Digitalmars-d-learn
Today's post doesn't just continue our look at Nodes-n-noodles (here's the link: https://gtkdcoding.com/2019/11/08/0086-nodes-v-node-drawing-routines.html) it's also a milestone for the GtkDcoding Blog... I've been accepted into the GitHub Sponsors program which means readers can now show their

is the runtime implemented in betterC?

2019-11-08 Thread dangbinghoo via Digitalmars-d-learn
hi, is the runtime d code implemented purely with betterC? i was thinking that what's happening when we building ARM dlang compiler, when the dlang compiler ready in the first, there's no ARM version of the runtime lib and phobos, so, it's likely we are using bare metal D and trying to build

Re: Using an async buffer

2019-11-08 Thread bioinfornatics via Digitalmars-d-learn
On Friday, 8 November 2019 at 01:12:37 UTC, Ali Çehreli wrote: On 11/07/2019 07:07 AM, bioinfornatics wrote: > Dear, > > I try to use the async buffer describe into std.parallelism > documentation but my test code core dump! I admit I don't fully understand the lifetime issues but removing the

Re: Using an async buffer

2019-11-08 Thread bioinfornatics via Digitalmars-d-learn
the error message was understandable to me, ... the error message was not understandable to me ...