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

[C++] Failure with -Werror=conversion on gcc 7.3.0

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 0.10.0
    • Component/s: C++

      Description

      Experienced this error building on Ubuntu 18.04 LTS / gcc 7.3.0

      /usr/bin/ccache /usr/bin/g++  -DARROW_EXTRA_ERROR_CONTEXT -DARROW_NO_DEPRECATED_API -isystem /home/wesm/cpp-toolchain/include -isystem gbenchmark_ep/src/gbenchmark_ep-install/include -isystem ../thirdparty/hadoop/include -isystem orc_ep-install/include -Isrc -I../src -isystem /home/wesm/miniconda/envs/arrow-dev/lib/python3.6/site-packages/numpy/core/include -isystem /home/wesm/miniconda/envs/arrow-dev/include/python3.6m -D_GLIBCXX_USE_CXX11_ABI=0 -ggdb -O0  -Wall -Wconversion -Wno-sign-conversion -Wno-unknown-warning-option -Werror -std=c++11 -msse3 -Werror -g -fPIC   -std=gnu++11 -MD -MT src/arrow/python/CMakeFiles/arrow_python_objlib.dir/arrow_to_pandas.cc.o -MF src/arrow/python/CMakeFiles/arrow_python_objlib.dir/arrow_to_pandas.cc.o.d -o src/arrow/python/CMakeFiles/arrow_python_objlib.dir/arrow_to_pandas.cc.o -c ../src/arrow/python/arrow_to_pandas.cc
      In file included from ../src/arrow/compute/kernel.h:28:0,
                       from ../src/arrow/compute/api.h:22,
                       from ../src/arrow/python/arrow_to_pandas.cc:46:
      ../src/arrow/util/variant.h:588:67: error: conversion to ‘unsigned int’ from ‘long unsigned int’ may alter its value [-Werror=conversion]
           static const std::size_t data_size = detail::static_max<sizeof(Types)...>::value;
                                                                         ^
      ../src/arrow/util/variant.h:589:79: error: conversion to ‘unsigned int’ from ‘long unsigned int’ may alter its value [-Werror=conversion]
           static const std::size_t data_align = detail::static_max<alignof(Types)...>::value;
                                                                                     ^
      cc1plus: error: unrecognized command line option ‘-Wno-unknown-warning-option’ [-Werror]
      cc1plus: all warnings being treated as errors
      

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                wesmckinn Wes McKinney
                Reporter:
                wesmckinn Wes McKinney
              • 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 - 1h 20m
                  1h 20m