[all-commits] [llvm/llvm-project] 5bccdd: [Matrix] Move C++ matrix cast checks to TryStaticC...
Florian Hahn via All-commits
all-commits at lists.llvm.org
Fri May 28 05:01:46 PDT 2021
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 5bccdde070d29fb83aec69c498285b4c8914f8d1
https://github.com/llvm/llvm-project/commit/5bccdde070d29fb83aec69c498285b4c8914f8d1
Author: Florian Hahn <flo at fhahn.com>
Date: 2021-05-28 (Fri, 28 May 2021)
Changed paths:
M clang/lib/Sema/SemaCast.cpp
M clang/test/CodeGenCXX/matrix-casts.cpp
M clang/test/SemaCXX/matrix-casts.cpp
Log Message:
-----------
[Matrix] Move C++ matrix cast checks to TryStaticCast.
At the moment, the matrix support in CheckCXXCStyleCast (added in
D101696) breaks function-style constructor calls that take a
single matrix value, because it is treated as matrix cast.
Instead, unify the C++ matrix cast handling by moving the logic to
TryStaticCast and only handle the case where both types are matrix
types. Otherwise, fall back to the generic mis-match detection.
Suggested by @rjmccall
Reviewed By: SaurabhJha
Differential Revision: https://reviews.llvm.org/D103163
More information about the All-commits
mailing list