Curl HTTP segfault

2016-02-24 Thread skilion via Digitalmars-d-learn
Hello everyone, I have had this problem for a little while but I don't understand if I'm am not using correctly the HTTP struct, or if it is a library bug. Hear is my code: http://pastebin.com/Pgx7bqum I get a segfault on exit in the destructor calling std.net.curl.Curl.shutdown() Workarou

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

2015-10-04 Thread skilion via Digitalmars-d-learn
On Sunday, 4 October 2015 at 21:57:44 UTC, Jonathan M Davis wrote: When appending, b to a, the elements in b are being copied onto the end of a, and presumably it works in this case, because a ubyte is implicitly convertible to char. But all it's doing is converting the individual elements. It'

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 }