pisa icon indicating copy to clipboard operation
pisa copied to clipboard

Live block computation

Open amallia opened this issue 5 years ago • 3 comments

Describe the bug https://github.com/pisa-engine/pisa/blob/f8c65c16342537237ce3bc877bec3cbf6d006172/test/test_wand_data.cpp#L108 Local variable i shadows outer variable.

amallia avatar Jul 19 '19 10:07 amallia

set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wextra")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wsign-compare")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wshadow")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wunused-parameter")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Werror")

may helpful

wanghenshui avatar Jul 22 '19 07:07 wanghenshui

@wanghenshui I'm all for extensive warnings, but do you have any idea if we can suppress warnings in the header-only libraries we depend on?

elshize avatar Sep 19 '19 20:09 elshize

suppress warnings in the header

https://stackoverflow.com/questions/1867065/how-to-suppress-gcc-warnings-from-library-headers


// save diagnostic state
#pragma GCC diagnostic push 

// turn off the specific warning. Can also use "-Wall"
#pragma GCC diagnostic ignored "-Wunused-but-set-variable"

#include <boost/uuid/uuid.hpp>
#include <boost/uuid/uuid_generators.hpp>
#include <boost/uuid/uuid_io.hpp>
#include <boost/lexical_cast.hpp>

// turn the warnings back on
#pragma GCC diagnostic pop

wanghenshui avatar Apr 15 '21 11:04 wanghenshui