explicitly specify error set of std.json.stringify

This commit is contained in:
Techatrix
2023-07-04 21:10:39 +02:00
committed by Andrew Kelley
parent 2b8c1f0d46
commit 3bf0b8eada
2 changed files with 1 additions and 18 deletions

View File

@@ -140,7 +140,7 @@ pub fn stringify(
value: anytype,
options: StringifyOptions,
out_stream: anytype,
) !void {
) @TypeOf(out_stream).Error!void {
const T = @TypeOf(value);
switch (@typeInfo(T)) {
.Float, .ComptimeFloat => {