[Issue 18851] New: std.net.curl.post cannot be used with !ubyte
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Thu May 10 21:47:24 UTC 2018
https://issues.dlang.org/show_bug.cgi?id=18851
Issue ID: 18851
Summary: std.net.curl.post cannot be used with !ubyte
Product: D
Version: D2
Hardware: x86_64
OS: Linux
Status: NEW
Severity: blocker
Priority: P1
Component: phobos
Assignee: nobody at puremagic.com
Reporter: tech.vindex at gmail.com
In file 'curl.d':
T[] post(T = char)(const(char)[] url, string[string] postDict, HTTP conn =
HTTP())
if (is(T == char) || is(T == ubyte)) //ignoring
{
import std.uri : urlEncode;
return post(url, urlEncode(postDict), conn); //post!char by default
}
Correctly:
T[] post(T = char)(const(char)[] url, string[string] postDict, HTTP conn =
HTTP())
if (is(T == char) || is(T == ubyte))
{
import std.uri : urlEncode;
return post!T(url, urlEncode(postDict), conn);
}
--
More information about the Digitalmars-d-bugs
mailing list