This is an archive of the discontinued LLVM Phabricator instance.

Extended format string checking to wprintf/wscanf
Needs ReviewPublic

Authored by MarcusJohnson91 on Jul 24 2021, 12:28 PM.

Details

Summary

Split from D103426

Diff Detail

Event Timeline

MarcusJohnson91 requested review of this revision.Jul 24 2021, 12:28 PM
Herald added a project: Restricted Project. · View Herald TranscriptJul 24 2021, 12:28 PM
Herald added a subscriber: cfe-commits. · View Herald Transcript
This comment was removed by MarcusJohnson91.

Clang-formatted the diff.

martong removed a subscriber: martong.Jul 29 2021, 7:31 AM
efriedma added inline comments.
clang/lib/AST/Expr.cpp
1081

getStringAsChar16?

clang/lib/AST/Type.cpp
1979

(The discussion of the typedefs on D103426 didn't really finish.)

clang/lib/Lex/LiteralSupport.cpp
1923

The math here probably needs to change for wide strings.

clang/lib/Sema/SemaChecking.cpp
9633

The math here looks suspicious... TypeSize is not in the same units as StrRef.size().

floam added a subscriber: floam.Oct 12 2021, 5:36 PM
This comment was removed by floam.