[libcxx] r331910 - Allow copy elision in path concatenation

2018-05-09 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Wed May 9 11:57:17 2018 New Revision: 331910 URL: http://llvm.org/viewvc/llvm-project?rev=331910=rev Log: Allow copy elision in path concatenation Summary: Just port of libstdc++'s fix to libc++ fs:

r333340 - [ClangDiagnostics] Silence warning about fallthrough after PrintFatalError

2018-05-26 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Sat May 26 02:24:00 2018 New Revision: 40 URL: http://llvm.org/viewvc/llvm-project?rev=40=rev Log: [ClangDiagnostics] Silence warning about fallthrough after PrintFatalError Summary: ClangDiagnosticsEmitter.cpp:1047:57: warning: this statement may fall through

r338385 - [RISCV] Add driver for riscv32-unknown-elf baremetal target

2018-07-31 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Tue Jul 31 07:21:46 2018 New Revision: 338385 URL: http://llvm.org/viewvc/llvm-project?rev=338385=rev Log: [RISCV] Add driver for riscv32-unknown-elf baremetal target Summary: This patch adds a driver for the baremetal RISC-V target (i.e. riscv32-unknown-elf). For

r338971 - Fix tests for changed opt remarks format

2018-08-05 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Sun Aug 5 07:53:34 2018 New Revision: 338971 URL: http://llvm.org/viewvc/llvm-project?rev=338971=rev Log: Fix tests for changed opt remarks format Summary: Optimization remark format is slightly changed by LLVM patch D49412. Two tests are fixed with expected messages

r344762 - [Test] Fix test file for C++98 mode

2018-10-18 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Thu Oct 18 14:26:01 2018 New Revision: 344762 URL: http://llvm.org/viewvc/llvm-project?rev=344762=rev Log: [Test] Fix test file for C++98 mode Modified: cfe/trunk/test/SemaCXX/enum.cpp Modified: cfe/trunk/test/SemaCXX/enum.cpp URL:

r344759 - [Diagnostics] Check for integer overflow in array size expressions

2018-10-18 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Thu Oct 18 13:49:06 2018 New Revision: 344759 URL: http://llvm.org/viewvc/llvm-project?rev=344759=rev Log: [Diagnostics] Check for integer overflow in array size expressions Summary: Fixes PR27439 Reviewers: rsmith, Rakete Reviewed By: rsmith Subscribers:

r344761 - [Diagnostics] Add missing expected warning to test file

2018-10-18 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Thu Oct 18 14:06:14 2018 New Revision: 344761 URL: http://llvm.org/viewvc/llvm-project?rev=344761=rev Log: [Diagnostics] Add missing expected warning to test file Modified: cfe/trunk/test/SemaCXX/enum.cpp Modified: cfe/trunk/test/SemaCXX/enum.cpp URL:

r345847 - [Diagnostics] Implement -Wsizeof-pointer-div

2018-11-01 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Thu Nov 1 09:26:10 2018 New Revision: 345847 URL: http://llvm.org/viewvc/llvm-project?rev=345847=rev Log: [Diagnostics] Implement -Wsizeof-pointer-div Summary: void test(int *arr) { int arr_len = sizeof(arr) / sizeof(*arr); // warn, incorrect way to compute number

r346866 - Reverted D52835 to fix review comments

2018-11-14 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Wed Nov 14 06:27:51 2018 New Revision: 346866 URL: http://llvm.org/viewvc/llvm-project?rev=346866=rev Log: Reverted D52835 to fix review comments Removed: cfe/trunk/test/Sema/impcast-integer-float.c Modified: cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td

r346865 - [Diagnostics] Check integer to floating point number implicit conversions

2018-11-14 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Wed Nov 14 06:24:33 2018 New Revision: 346865 URL: http://llvm.org/viewvc/llvm-project?rev=346865=rev Log: [Diagnostics] Check integer to floating point number implicit conversions Summary: GCC already catches these situations so we should handle it too. GCC warns in C++

r343560 - Added warning for unary minus used with unsigned type

2018-10-02 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Mon Oct 1 23:02:30 2018 New Revision: 343560 URL: http://llvm.org/viewvc/llvm-project?rev=343560=rev Log: Added warning for unary minus used with unsigned type Summary: Inspired by MSVC, which found some occurrences of this expression on our code base. Fixes PR38950

r342139 - Print correctly dependency paths on Windows

2018-09-13 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Thu Sep 13 07:27:32 2018 New Revision: 342139 URL: http://llvm.org/viewvc/llvm-project?rev=342139=rev Log: Print correctly dependency paths on Windows Summary: Before: main.o: main.c ../include/lib\test.h After: main.o: main.c ../include/lib/test.h Fixes PR38877

r360810 - [clang-format] Fixed self assignment

2019-05-15 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Wed May 15 13:29:33 2019 New Revision: 360810 URL: http://llvm.org/viewvc/llvm-project?rev=360810=rev Log: [clang-format] Fixed self assignment Reviewers: MyDeveloperDay, RKSimon Reviewed By: MyDeveloperDay Subscribers: RKSimon, cfe-commits Tags: #clang Differential

r359516 - [Diagnostics] Support -Wtype-limits for GCC compatibility

2019-04-29 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Mon Apr 29 16:24:00 2019 New Revision: 359516 URL: http://llvm.org/viewvc/llvm-project?rev=359516=rev Log: [Diagnostics] Support -Wtype-limits for GCC compatibility Summary: GCC's -Wtype-limits (part of -Wextra): Warn if a comparison is always true or always false due to

r368725 - [NFC] Updated tests after r368724

2019-08-13 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Tue Aug 13 10:19:16 2019 New Revision: 368725 URL: http://llvm.org/viewvc/llvm-project?rev=368725=rev Log: [NFC] Updated tests after r368724 Modified: cfe/trunk/test/CodeGen/tbaa-struct.cpp Modified: cfe/trunk/test/CodeGen/tbaa-struct.cpp URL:

r368809 - [Codegen] Updated test for D66158

2019-08-14 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Wed Aug 14 01:32:31 2019 New Revision: 368809 URL: http://llvm.org/viewvc/llvm-project?rev=368809=rev Log: [Codegen] Updated test for D66158 Reviewers: jdoerfert Reviewed By: jdoerfert Subscribers: cfe-commits Tags: #clang Differential Revision:

r368828 - [NFC] Make test more robust

2019-08-14 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Wed Aug 14 04:13:10 2019 New Revision: 368828 URL: http://llvm.org/viewvc/llvm-project?rev=368828=rev Log: [NFC] Make test more robust Currently fails on ARMs Modified: cfe/trunk/test/CodeGen/struct-copy.c Modified: cfe/trunk/test/CodeGen/struct-copy.c URL:

r369206 - [Diagnostics] Improve -Wsizeof-pointer-div

2019-08-18 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Sun Aug 18 03:10:09 2019 New Revision: 369206 URL: http://llvm.org/viewvc/llvm-project?rev=369206=rev Log: [Diagnostics] Improve -Wsizeof-pointer-div Emit diag note with a location of pointer declaration. Revisited/added tests. Modified:

r369217 - [Diagnostics] Diagnose misused xor as pow

2019-08-18 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Sun Aug 18 12:14:14 2019 New Revision: 369217 URL: http://llvm.org/viewvc/llvm-project?rev=369217=rev Log: [Diagnostics] Diagnose misused xor as pow Summary: Motivation: https://twitter.com/jfbastien/status/1139298419988549632

r368658 - [NFC] Updated tests after r368657

2019-08-13 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Tue Aug 13 02:12:07 2019 New Revision: 368658 URL: http://llvm.org/viewvc/llvm-project?rev=368658=rev Log: [NFC] Updated tests after r368657 Modified: cfe/trunk/test/CodeGen/tbaa-struct.cpp cfe/trunk/test/CodeGenCXX/auto-var-init.cpp Modified:

r368863 - [NFC] Fix testcase for ARMs

2019-08-14 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Wed Aug 14 08:35:40 2019 New Revision: 368863 URL: http://llvm.org/viewvc/llvm-project?rev=368863=rev Log: [NFC] Fix testcase for ARMs Modified: cfe/trunk/test/CodeGen/struct-copy.c Modified: cfe/trunk/test/CodeGen/struct-copy.c URL:

r368876 - [NFC] Updated tests after r368875

2019-08-14 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Wed Aug 14 09:50:34 2019 New Revision: 368876 URL: http://llvm.org/viewvc/llvm-project?rev=368876=rev Log: [NFC] Updated tests after r368875 Modified: cfe/trunk/test/CodeGen/tbaa-struct.cpp Modified: cfe/trunk/test/CodeGen/tbaa-struct.cpp URL:

r370595 - [NFC] Fix for rL370594

2019-08-31 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Sat Aug 31 11:35:44 2019 New Revision: 370595 URL: http://llvm.org/viewvc/llvm-project?rev=370595=rev Log: [NFC] Fix for rL370594 Modified: cfe/trunk/include/clang/Basic/DiagnosticGroups.td cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td Modified:

r370594 - [clang] Warning for non-final classes with final destructors

2019-08-31 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Sat Aug 31 11:31:19 2019 New Revision: 370594 URL: http://llvm.org/viewvc/llvm-project?rev=370594=rev Log: [clang] Warning for non-final classes with final destructors Marking a class' destructor final prevents the class from being inherited from. However, it is a subtle

r370597 - [clang] Devirtualization for classes with destructors marked as 'final'

2019-08-31 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Sat Aug 31 11:52:44 2019 New Revision: 370597 URL: http://llvm.org/viewvc/llvm-project?rev=370597=rev Log: [clang] Devirtualization for classes with destructors marked as 'final' A class with a destructor marked final cannot be derived from, so it should afford the same

r370740 - Fixit for -Wfinal-dtor-non-final-class

2019-09-03 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Tue Sep 3 03:54:25 2019 New Revision: 370740 URL: http://llvm.org/viewvc/llvm-project?rev=370740=rev Log: Fixit for -Wfinal-dtor-non-final-class Modified: cfe/trunk/lib/Sema/SemaDeclCXX.cpp cfe/trunk/test/SemaCXX/warn-final-dtor-non-final-class.cpp Modified:

r370737 - Added fixit notes for -Wfinal-dtor-non-final-class

2019-09-03 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Tue Sep 3 03:32:21 2019 New Revision: 370737 URL: http://llvm.org/viewvc/llvm-project?rev=370737=rev Log: Added fixit notes for -Wfinal-dtor-non-final-class Modified: cfe/trunk/lib/Sema/SemaDeclCXX.cpp cfe/trunk/test/SemaCXX/warn-final-dtor-non-final-class.cpp

r371122 - [Diagnostics] Minor improvements for -Wxor-used-as-pow

2019-09-05 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Thu Sep 5 13:50:48 2019 New Revision: 371122 URL: http://llvm.org/viewvc/llvm-project?rev=371122=rev Log: [Diagnostics] Minor improvements for -Wxor-used-as-pow Extracted from D66397; implemented suggestion for 2^64; tests revisited. Modified:

r371646 - [NFC] Added triple to test file to avoid arm buildbots failures

2019-09-11 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Wed Sep 11 11:55:56 2019 New Revision: 371646 URL: http://llvm.org/viewvc/llvm-project?rev=371646=rev Log: [NFC] Added triple to test file to avoid arm buildbots failures Modified: cfe/trunk/test/Sema/div-sizeof-array.cpp Modified:

r371605 - [Diagnostics] Add -Wsizeof-array-div

2019-09-11 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Wed Sep 11 03:59:47 2019 New Revision: 371605 URL: http://llvm.org/viewvc/llvm-project?rev=371605=rev Log: [Diagnostics] Add -Wsizeof-array-div Summary: Clang version of https://www.viva64.com/en/examples/v706/ Reviewers: rsmith Differential Revision:

r371924 - [Diagnostics] Added silence note for -Wsizeof-array-div; suggest extra parens

2019-09-14 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Sat Sep 14 12:38:55 2019 New Revision: 371924 URL: http://llvm.org/viewvc/llvm-project?rev=371924=rev Log: [Diagnostics] Added silence note for -Wsizeof-array-div; suggest extra parens Modified: cfe/trunk/lib/Sema/SemaExpr.cpp

r372095 - [NFC] Updated test

2019-09-17 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Tue Sep 17 02:53:14 2019 New Revision: 372095 URL: http://llvm.org/viewvc/llvm-project?rev=372095=rev Log: [NFC] Updated test Modified: cfe/trunk/test/CodeGen/tbaa-struct.cpp Modified: cfe/trunk/test/CodeGen/tbaa-struct.cpp URL:

r371226 - [NFCI] Unbreak buildbots

2019-09-06 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Fri Sep 6 09:30:44 2019 New Revision: 371226 URL: http://llvm.org/viewvc/llvm-project?rev=371226=rev Log: [NFCI] Unbreak buildbots Removed: cfe/trunk/test/Sema/div-sizeof-array.cpp Modified: cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td

r371222 - [Diagnostics] Refactor code for -Wsizeof-pointer-div, catch more cases; also add -Wsizeof-array-div

2019-09-06 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Fri Sep 6 09:12:48 2019 New Revision: 371222 URL: http://llvm.org/viewvc/llvm-project?rev=371222=rev Log: [Diagnostics] Refactor code for -Wsizeof-pointer-div, catch more cases; also add -Wsizeof-array-div Previously, -Wsizeof-pointer-div failed to catch: const int *r;

r371223 - [NFC] Added new tests for r371222

2019-09-06 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Fri Sep 6 09:18:18 2019 New Revision: 371223 URL: http://llvm.org/viewvc/llvm-project?rev=371223=rev Log: [NFC] Added new tests for r371222 Added: cfe/trunk/test/Sema/div-sizeof-array.cpp Added: cfe/trunk/test/Sema/div-sizeof-array.cpp URL:

r373345 - [Diagnostics] Move warning into the subgroup (-Wenum-compare-conditional)

2019-10-01 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Tue Oct 1 08:44:38 2019 New Revision: 373345 URL: http://llvm.org/viewvc/llvm-project?rev=373345=rev Log: [Diagnostics] Move warning into the subgroup (-Wenum-compare-conditional) Modified: cfe/trunk/include/clang/Basic/DiagnosticGroups.td

r372612 - [Diagnostics] Warn if '<<' in bool context with -Wint-in-bool-context (GCC compatibility)

2019-09-23 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Mon Sep 23 07:21:08 2019 New Revision: 372612 URL: http://llvm.org/viewvc/llvm-project?rev=372612=rev Log: [Diagnostics] Warn if '<<' in bool context with -Wint-in-bool-context (GCC compatibility) Extracted from D63082, addressed review comments related to a warning

r372709 - [NFC] Update test after r372708

2019-09-24 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Tue Sep 24 02:24:48 2019 New Revision: 372709 URL: http://llvm.org/viewvc/llvm-project?rev=372709=rev Log: [NFC] Update test after r372708 Modified: cfe/trunk/test/SemaCXX/cxx2a-explicit-bool.cpp Modified: cfe/trunk/test/SemaCXX/cxx2a-explicit-bool.cpp URL:

r372708 - [Diagnostics] Do not diagnose unsigned shifts in boolean context (-Wint-in-bool-context)

2019-09-24 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Tue Sep 24 02:14:33 2019 New Revision: 372708 URL: http://llvm.org/viewvc/llvm-project?rev=372708=rev Log: [Diagnostics] Do not diagnose unsigned shifts in boolean context (-Wint-in-bool-context) I was looking at old GCC's patch. Current "trunk" version avoids warning for

r372575 - [NFC] Fixed clang wasm test after rL372573

2019-09-23 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Mon Sep 23 03:14:07 2019 New Revision: 372575 URL: http://llvm.org/viewvc/llvm-project?rev=372575=rev Log: [NFC] Fixed clang wasm test after rL372573 These tests should not depend on -O1.. Modified: cfe/trunk/test/CodeGenCXX/wasm-args-returns.cpp Modified:

r372664 - [Diagnostics] Warn for enum constants in bool context (-Wint-in-bool-context; GCC compatibility)

2019-09-23 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Mon Sep 23 15:09:49 2019 New Revision: 372664 URL: http://llvm.org/viewvc/llvm-project?rev=372664=rev Log: [Diagnostics] Warn for enum constants in bool context (-Wint-in-bool-context; GCC compatibility) Extracted from D63082. Modified:

r372749 - [Diagnostics] Handle tautological left shifts in boolean context

2019-09-24 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Tue Sep 24 06:14:18 2019 New Revision: 372749 URL: http://llvm.org/viewvc/llvm-project?rev=372749=rev Log: [Diagnostics] Handle tautological left shifts in boolean context Modified: cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td

r373252 - [Diagnostics] Warn if enumeration type mismatch in conditional expression

2019-09-30 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Mon Sep 30 12:55:50 2019 New Revision: 373252 URL: http://llvm.org/viewvc/llvm-project?rev=373252=rev Log: [Diagnostics] Warn if enumeration type mismatch in conditional expression Summary: - Useful warning - GCC compatibility (GCC warns in C++ mode) Reviewers: rsmith,

r373256 - [NFCI] Updated broken test

2019-09-30 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Mon Sep 30 13:23:22 2019 New Revision: 373256 URL: http://llvm.org/viewvc/llvm-project?rev=373256=rev Log: [NFCI] Updated broken test Modified: cfe/trunk/test/SemaCXX/warn-sign-conversion.cpp Modified: cfe/trunk/test/SemaCXX/warn-sign-conversion.cpp URL:

r373258 - [NFC] Fix tests, second try

2019-09-30 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Mon Sep 30 13:41:56 2019 New Revision: 373258 URL: http://llvm.org/viewvc/llvm-project?rev=373258=rev Log: [NFC] Fix tests, second try Modified: cfe/trunk/test/SemaCXX/warn-sign-conversion.cpp Modified: cfe/trunk/test/SemaCXX/warn-sign-conversion.cpp URL:

r373375 - [NFC] Updated tests after rL373371

2019-10-01 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Tue Oct 1 11:18:45 2019 New Revision: 373375 URL: http://llvm.org/viewvc/llvm-project?rev=373375=rev Log: [NFC] Updated tests after rL373371 Forgot to run check-clang-semacxx. Modified: cfe/trunk/test/SemaCXX/warn-sign-conversion.cpp Modified:

r373371 - [Diagnostics] Make -Wenum-compare-conditional off by default

2019-10-01 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Tue Oct 1 11:12:13 2019 New Revision: 373371 URL: http://llvm.org/viewvc/llvm-project?rev=373371=rev Log: [Diagnostics] Make -Wenum-compare-conditional off by default Too many false positives, eg. in Chromium. Modified:

r372775 - [NFC] Strenghten preconditions for warning

2019-09-24 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Tue Sep 24 13:10:57 2019 New Revision: 372775 URL: http://llvm.org/viewvc/llvm-project?rev=372775=rev Log: [NFC] Strenghten preconditions for warning Modified: cfe/trunk/lib/Sema/SemaChecking.cpp Modified: cfe/trunk/lib/Sema/SemaChecking.cpp URL:

r372533 - [NFC] Fixed failed test

2019-09-22 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Sun Sep 22 15:15:11 2019 New Revision: 372533 URL: http://llvm.org/viewvc/llvm-project?rev=372533=rev Log: [NFC] Fixed failed test Modified: cfe/trunk/test/SemaCXX/constexpr-builtin-bit-cast.cpp Modified: cfe/trunk/test/SemaCXX/constexpr-builtin-bit-cast.cpp URL:

r372531 - [Diagnostics] Warn if ?: with integer constants always evaluates to true

2019-09-22 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Sun Sep 22 15:00:48 2019 New Revision: 372531 URL: http://llvm.org/viewvc/llvm-project?rev=372531=rev Log: [Diagnostics] Warn if ?: with integer constants always evaluates to true Extracted from D63082. GCC has this warning under -Wint-in-bool-context, but as noted in the

r372600 - [Diagnostics] Avoid -Wsizeof-array-div when dividing the size of a nested array by the size of the deepest base type

2019-09-23 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Mon Sep 23 05:54:35 2019 New Revision: 372600 URL: http://llvm.org/viewvc/llvm-project?rev=372600=rev Log: [Diagnostics] Avoid -Wsizeof-array-div when dividing the size of a nested array by the size of the deepest base type Modified: cfe/trunk/lib/Sema/SemaExpr.cpp

r373973 - [Diagnostics] Emit better -Wbool-operation's warning message if we known that the result is always true

2019-10-07 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Mon Oct 7 14:57:03 2019 New Revision: 373973 URL: http://llvm.org/viewvc/llvm-project?rev=373973=rev Log: [Diagnostics] Emit better -Wbool-operation's warning message if we known that the result is always true Modified:

r373817 - [Diagnostics] Use Expr::isKnownToHaveBooleanValue() to check bitwise negation of bool in languages without a bool type

2019-10-05 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Sat Oct 5 01:02:11 2019 New Revision: 373817 URL: http://llvm.org/viewvc/llvm-project?rev=373817=rev Log: [Diagnostics] Use Expr::isKnownToHaveBooleanValue() to check bitwise negation of bool in languages without a bool type Thanks for this advice, Richard Trieu!

r373818 - [NFCI] Slightly improve warning message

2019-10-05 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Sat Oct 5 01:09:06 2019 New Revision: 373818 URL: http://llvm.org/viewvc/llvm-project?rev=373818=rev Log: [NFCI] Slightly improve warning message Modified: cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td cfe/trunk/test/SemaCXX/warn-xor-as-pow.cpp Modified:

r373828 - [Diagnostics] Highlight expr's source range for -Wbool-operation

2019-10-05 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Sat Oct 5 06:28:15 2019 New Revision: 373828 URL: http://llvm.org/viewvc/llvm-project?rev=373828=rev Log: [Diagnostics] Highlight expr's source range for -Wbool-operation Warning message looks better; and GCC adds it too. Modified: cfe/trunk/lib/Sema/SemaExpr.cpp

r373743 - [NFCI] Improve the -Wbool-operation's warning message

2019-10-04 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Fri Oct 4 05:55:13 2019 New Revision: 373743 URL: http://llvm.org/viewvc/llvm-project?rev=373743=rev Log: [NFCI] Improve the -Wbool-operation's warning message Based on the request from the post commit review. Also added one new test. Modified:

r373616 - [NFC] Added missing changes for rL373614

2019-10-03 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Thu Oct 3 08:26:26 2019 New Revision: 373616 URL: http://llvm.org/viewvc/llvm-project?rev=373616=rev Log: [NFC] Added missing changes for rL373614 Modified: cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td Modified:

r373614 - [Diagnostics] Bitwise negation of a boolean expr always evaluates to true; warn with -Wbool-operation

2019-10-03 Thread David Bolvansky via cfe-commits
Author: xbolva00 Date: Thu Oct 3 08:17:59 2019 New Revision: 373614 URL: http://llvm.org/viewvc/llvm-project?rev=373614=rev Log: [Diagnostics] Bitwise negation of a boolean expr always evaluates to true; warn with -Wbool-operation Requested here: