Skip to content
Snippets Groups Projects
Commit 9e5925c9 authored by Radek Hušek's avatar Radek Hušek Committed by Radek Hušek
Browse files

Silence compiler warnings

parent 587e51d5
No related branches found
No related tags found
No related merge requests found
......@@ -47,7 +47,7 @@ struct Tester : public AbstractTester {
# if !USE_NEXT_FORB
size_t numForb;
# endif
int edges;
size_t edges;
std::vector<EdgeId> classEdges;
std::vector< std::pair<EdgeId, Mapping> > nonClassEdges;
......
......@@ -9,7 +9,10 @@ setup(
Extension("groupConnectivity",
sources = ["groupConnectivity.pyx"],
language="c++",
extra_compile_args=["-std=gnu++11", "-O2", "-funroll-loops"]
extra_compile_args=[
"-std=gnu++11", "-O2", "-funroll-loops", "-fwrapv",
"-Wall", "-fno-strict-aliasing"
]
)
])
)
......
......@@ -9,9 +9,9 @@ struct TwoCutInt {
static const int num_classes = (Ring::size * (Ring::size - 1)) / 2;
struct Tables {
char decodeMatrix[Ring::size][Ring::size];
struct { char a, b; } encodeTable[max_value];
char classMatrix[Ring::size][Ring::size];
signed char decodeMatrix[Ring::size][Ring::size];
struct { signed char a, b; } encodeTable[max_value];
signed char classMatrix[Ring::size][Ring::size];
Tables() {
encodeTable[0] = {1, 2};
......@@ -30,7 +30,7 @@ struct TwoCutInt {
memset(classMatrix, -1, sizeof(classMatrix));
struct { char a, b; } classTable[num_classes];
struct { signed char a, b; } classTable[num_classes];
classTable[0] = {0, 1};
for (int i = 1; i < num_classes; i++) {
......@@ -59,7 +59,6 @@ struct TwoCutInt {
}
inline int getClass(const Mapping &map) const {
int ret = S.classMatrix[map[a]][flip ? Ring::negate(map[b]) : map[b]];
return S.classMatrix[map[a]][flip ? Ring::negate(map[b]) : map[b]];
}
};
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment