You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on May 12, 2023. It is now read-only.
std::shared_ptr<int64_t> data
data is generated as int64_t instead of uint32_t.
data_constraint(0, 4294967295, boost::none, boost::none, boost::none)
Due to the maximum value is 4294967295 hence it is -1 if the type is int64_t. Hence any value pass to data, constraint check will throw exception.
Can you let me know where from the generator is generating int64_t instead of uint32_t from the format tag in YAML file?
Appreciate if you can shed some light to point me out how it is worked and where can I modify the tool.
Thanks.
The text was updated successfully, but these errors were encountered:
Hey @junhan87, I am sorry, I could have sworn I had archived this 🤔
I am working (almost every day) on our own model generation tool under the AsyncAPI umbrella called Modelina. We just recently added C++ support, however, all of these different types are not supported, however easily achievable! I am more than happy to help over there, feel free to reach out on the AsyncAPI slack if you find this interesting.
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Hi, I am using this template to geenerate C++ code. I am having issue that the generated data type is not the same as YAML file.
YAML file:
From above snippet, the format is set as uint32 and max is set to 4294967295 for unsigned type.
Then running this command:
Generated code:
std::shared_ptr<int64_t> data
data is generated as int64_t instead of uint32_t.
data_constraint(0, 4294967295, boost::none, boost::none, boost::none)
Due to the maximum value is 4294967295 hence it is -1 if the type is int64_t. Hence any value pass to data, constraint check will throw exception.
Can you let me know where from the generator is generating int64_t instead of uint32_t from the format tag in YAML file?
Appreciate if you can shed some light to point me out how it is worked and where can I modify the tool.
Thanks.
The text was updated successfully, but these errors were encountered: