Skip to content

Commit ecc8433

Browse files
committed
Slightly better error message for fromJSON
1 parent bf039ac commit ecc8433

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

source/iopipe/json/serialize.d

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -727,6 +727,7 @@ void deserializeImpl(P, T, JT)(ref P policy, ref JT tokenizer, ref T item) if (i
727727
item = T.fromJSON(tokenizer);
728728
} else {
729729
// This will fail to compile. Try to nudge the user to use a policy
730+
pragma(msg, "Hint: fromJSON also doesn't compile with parameters (JSONTokenizer, ReleasePolicy) or or just with (JSONTokenizer)");
730731
item = T.fromJSON(tokenizer, policy);
731732
}
732733
}

0 commit comments

Comments
 (0)