[all-commits] [llvm/llvm-project] 84c934: Silence compiler warning. NFC.
Michael Kruse via All-commits
all-commits at lists.llvm.org
Mon Feb 10 09:39:25 PST 2020
Branch: refs/heads/master
Home: https://github.com/llvm/llvm-project
Commit: 84c934a5cbe2fdb7e0bb61a94e4dfa5e6cc3e0b2
https://github.com/llvm/llvm-project/commit/84c934a5cbe2fdb7e0bb61a94e4dfa5e6cc3e0b2
Author: Michael Kruse <llvm-project at meinersbur.de>
Date: 2020-02-10 (Mon, 10 Feb 2020)
Changed paths:
M polly/lib/Support/ISLTools.cpp
Log Message:
-----------
Silence compiler warning. NFC.
The idiom
for (auto i = n - n; i < n; i += 1)
was intended to automatically derive the type of i from n
(signed/unsigned int) and avoid the 'mixed signed/unsigned comparison'
warning. However, almost-always-auto was never used in the LLVM coding
style (although we used it in Polly for some time) and I did never
intended to use this idiom upstream.
PVS Studio may warns about this idiom as 'warning: both sides of
operator are equivalent [misc-redundant-expression]'.
Remove the use of auto and directly use unsigned.
Also see http://llvm.org/PR44768
More information about the All-commits
mailing list