awslabs / aws-crt-cpp

C++ wrapper around the aws-c-* libraries. Provides Cross-Platform Transport Protocols and SSL/TLS implementations for C++.
Apache License 2.0
73 stars 64 forks source link

make variant index casts more explicit #635

Closed DmitriyMusatkin closed 1 month ago

DmitriyMusatkin commented 1 month ago

Issue #, if available:

Description of changes: result of short + short is always an int (one of those weird c++ standard quirks), so when we write the result back to a short field some compilers might raise a warning for it if -Wconversion is on (which it is typically not, since its not part of -Wall, etc...). So be more explicit casting back

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.