@@ -157,6 +157,7 @@ Distributed under the Boost Software License, Version 1.0.
157
157
module std.net.curl ;
158
158
159
159
public import etc.c.curl : CurlOption;
160
+ import etc.c.curl : CURLcode;
160
161
import std.concurrency : Tid;
161
162
import std.range.primitives ;
162
163
import std.encoding : EncodingScheme;
@@ -165,6 +166,8 @@ import std.typecons : Flag, Yes, No, Tuple;
165
166
166
167
version (unittest )
167
168
{
169
+ import std.socket : Socket ;
170
+
168
171
// Run unit test with the PHOBOS_TEST_ALLOW_NET=1 set in order to
169
172
// allow net traffic
170
173
private struct TestServer
@@ -232,11 +235,8 @@ version(unittest)
232
235
immutable (T)[] bdy;
233
236
}
234
237
235
- private Request! T recvReq (T=char , S)(S s)
238
+ private Request! T recvReq (T=char )( Socket s)
236
239
{
237
- import std.socket : Socket ;
238
- static assert (is (S == Socket ), " Invalid type used. Use std.socket.Socket." );
239
-
240
240
import std.algorithm.comparison : min;
241
241
import std.algorithm.searching : find, canFind;
242
242
import std.conv : to;
@@ -4144,7 +4144,6 @@ class HTTPStatusException : CurlException
4144
4144
immutable int status; // / The HTTP status code
4145
4145
}
4146
4146
4147
- import etc.c.curl : CURLcode;
4148
4147
// / Equal to $(REF CURLcode, etc,c,curl)
4149
4148
alias CurlCode = CURLcode;
4150
4149
@@ -4352,7 +4351,7 @@ struct Curl
4352
4351
interleavefunction, chunk_data, chunk_bgn_function,
4353
4352
chunk_end_function, fnmatch_data, fnmatch_function, cookiejar, postfields);
4354
4353
4355
- static foreach (option; tt)
4354
+ foreach (option; tt)
4356
4355
copy.clear(option);
4357
4356
}
4358
4357
0 commit comments