-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
json2.decoder2: prepare decoder in json2 to be replaced by json2.decode2 #23078
Conversation
No, deprecations of public functions take time. Add at least 1 month starting from today. Alternatively, just do not deprecate the method, and leave it as it is, including its tests. |
I prefer to make them deprecated. When x.json2 becomes just json, probably none of these methods will be part of the library. I hope |
They are public API, public APIs should have a deprecation period. It is very rude to users of your libraries, to make breaking changes like this, especially if you have an easy way to avoid it. |
res := raw_decode(src)!.as_map() | ||
return decode_struct[T](T{}, res) | ||
} | ||
|
||
// decode_array is a generic function that decodes a JSON string into the array target type. | ||
pub fn decode_array[T](src string) ![]T { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
moved to vlib/x/json2/decoder_deprecated.v
Huly®: V_0.6-21517