[all-commits] [llvm/llvm-project] a870a4: [HLSL] Fix casting asserts (#82827)
Farzon Lotfi via All-commits
all-commits at lists.llvm.org
Mon Feb 26 14:12:26 PST 2024
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: a870a48c09ea32a5c179e827ed60e53e748cbc49
https://github.com/llvm/llvm-project/commit/a870a48c09ea32a5c179e827ed60e53e748cbc49
Author: Farzon Lotfi <1802579+farzonl at users.noreply.github.com>
Date: 2024-02-26 (Mon, 26 Feb 2024)
Changed paths:
M clang/lib/Sema/SemaExprCXX.cpp
M clang/lib/Sema/SemaOverload.cpp
M clang/test/SemaHLSL/VectorOverloadResolution.hlsl
Log Message:
-----------
[HLSL] Fix casting asserts (#82827)
There are two issues here. first `ICK_Floating_Integral` were always
defaulting to `CK_FloatingToIntegral` for vectors regardless of
direction of cast. Check was scalar only so added a vec float check to
the conditional.
Second issue was float to int casts were resolving to
ICK_Integral_Promotion when they need to be resolving to
CK_FloatingToIntegral. This was fixed by changing the ordering of
conversion checks.
This fixes #82826
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list