Uploaded image for project: 'Apache Arrow'
  1. Apache Arrow
  2. ARROW-2505

[C++] Disable MSVC warning C4800

    XMLWordPrintableJSON

    Details

      Description

      This warning is practically pointless, and since we treat warnings as errors on Appveyor, it imposes spurious back-and-forths to fix it when it occurs.

      https://docs.microsoft.com/en-us/cpp/error-messages/compiler-warnings/compiler-warning-level-3-c4800

      This warning is generated when a value that is not bool is assigned or coerced into type bool. Typically, this message is caused by assigning int variables to bool variables where the int variable contains only values true and false, and could be redeclared as type bool. If you cannot rewrite the expression to use type bool, then you can add "!=0" to the expression, which gives the expression type bool. Casting the expression to type bool does not disable the warning, which is by design.

      This warning is no longer generated in Visual Studio 2017.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                apitrou Antoine Pitrou
                Reporter:
                apitrou Antoine Pitrou
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 20m
                  20m