mirror of
https://github.com/dlang/phobos.git
synced 2025-04-28 14:10:30 +03:00
std.json: Remove unused error parameter to appendJSONChar
This commit is contained in:
parent
e59ce88531
commit
145f279b42
1 changed files with 3 additions and 5 deletions
|
@ -835,7 +835,7 @@ if (isInputRange!T && !isInfinite!T && isSomeChar!(ElementEncodingType!T))
|
|||
|
||||
default:
|
||||
auto c = getChar();
|
||||
appendJSONChar(str, c, options, &error);
|
||||
appendJSONChar(str, c, options);
|
||||
goto Next;
|
||||
}
|
||||
|
||||
|
@ -1113,8 +1113,7 @@ string toJSON(const ref JSONValue root, in bool pretty = false, in JSONOptions o
|
|||
case '\r': json.put("\\r"); break;
|
||||
case '\t': json.put("\\t"); break;
|
||||
default:
|
||||
appendJSONChar(json, c, options,
|
||||
(msg) { throw new JSONException(msg); });
|
||||
appendJSONChar(json, c, options);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1281,8 +1280,7 @@ string toJSON(const ref JSONValue root, in bool pretty = false, in JSONOptions o
|
|||
return json.data;
|
||||
}
|
||||
|
||||
private void appendJSONChar(ref Appender!string dst, dchar c, JSONOptions opts,
|
||||
scope void delegate(string) error) @safe
|
||||
private void appendJSONChar(ref Appender!string dst, dchar c, JSONOptions opts) @safe
|
||||
{
|
||||
import std.uni : isControl;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue