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
We make an FFI call to clang_getNumElements but don't check the return value. We should check for failure and return None if we find it, only casting to usize and returning Some after we've verified a successful result.
We make an FFI call to
clang_getNumElements
but don't check the return value. We should check for failure and returnNone
if we find it, only casting to usize and returningSome
after we've verified a successful result.http://clang.llvm.org/doxygen/group__CINDEX__TYPES.html#gac5f636020c388126bec572cb1fb13007
This will be one less foot gun for callers that currently need to remember to check (for
std::usize::MAX == -1 as usize
? I doubt any do...).I can mentor whoever wants to work on this.
The text was updated successfully, but these errors were encountered: