digitalmars.D.learn - Error: cannot implicitly convert expression
- Suliman (11/11) Oct 23 2014 import std.stdio;
- Suliman (3/3) Oct 23 2014 Solution
- Jonathan M Davis (7/10) Oct 23 2014 It certainly looks like one. std.net.curl's documentation
import std.stdio; import std.conv; import std.string; import std.net.curl; void main() { string content = get("d-lang.appspot.com/testUrl2"); } Error: cannot implicitly convert expression (get("d-lang.appsp ot.com/testUrl2", AutoProtocol())) of type char[] to string code from: http://dlang.org/phobos/std_net_curl.html#get
Oct 23 2014
Solution http://forum.dlang.org/thread/bgkklxwbhrqdhvethnco forum.dlang.org#post-l639dt:24vlj:241:40digitalmars.com Am I right understand that it's bug in doc?
Oct 23 2014
On Thursday, 23 October 2014 at 19:18:33 UTC, Suliman wrote:Solution http://forum.dlang.org/thread/bgkklxwbhrqdhvethnco forum.dlang.org#post-l639dt:24vlj:241:40digitalmars.com Am I right understand that it's bug in doc?It certainly looks like one. std.net.curl's documentation examples aren't generally generated with ddoc-ed unittest blocks (because that would require hitting sites on the internet), so its examples are more likely to be buggy than is the case with many other modules. - Jonathan M Davis
Oct 23 2014