Skip to content

Commit 166e5f3

Browse files
committed
Address review
1 parent ca0777a commit 166e5f3

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

std/net/curl.d

+5-6
Original file line numberDiff line numberDiff line change
@@ -157,6 +157,7 @@ Distributed under the Boost Software License, Version 1.0.
157157
module std.net.curl;
158158

159159
public import etc.c.curl : CurlOption;
160+
import etc.c.curl : CURLcode;
160161
import std.concurrency : Tid;
161162
import std.range.primitives;
162163
import std.encoding : EncodingScheme;
@@ -165,6 +166,8 @@ import std.typecons : Flag, Yes, No, Tuple;
165166

166167
version(unittest)
167168
{
169+
import std.socket : Socket;
170+
168171
// Run unit test with the PHOBOS_TEST_ALLOW_NET=1 set in order to
169172
// allow net traffic
170173
private struct TestServer
@@ -232,11 +235,8 @@ version(unittest)
232235
immutable(T)[] bdy;
233236
}
234237

235-
private Request!T recvReq(T=char, S)(S s)
238+
private Request!T recvReq(T=char)(Socket s)
236239
{
237-
import std.socket : Socket;
238-
static assert (is(S == Socket), "Invalid type used. Use std.socket.Socket.");
239-
240240
import std.algorithm.comparison : min;
241241
import std.algorithm.searching : find, canFind;
242242
import std.conv : to;
@@ -4144,7 +4144,6 @@ class HTTPStatusException : CurlException
41444144
immutable int status; /// The HTTP status code
41454145
}
41464146

4147-
import etc.c.curl : CURLcode;
41484147
/// Equal to $(REF CURLcode, etc,c,curl)
41494148
alias CurlCode = CURLcode;
41504149

@@ -4352,7 +4351,7 @@ struct Curl
43524351
interleavefunction, chunk_data, chunk_bgn_function,
43534352
chunk_end_function, fnmatch_data, fnmatch_function, cookiejar, postfields);
43544353

4355-
static foreach (option; tt)
4354+
foreach (option; tt)
43564355
copy.clear(option);
43574356
}
43584357

0 commit comments

Comments
 (0)