Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
B
boolinq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
boolinq
Commits
fe0107e2
Commit
fe0107e2
authored
May 19, 2016
by
Anton Bukov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed some warnings
parent
0b63c132
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
22 additions
and
22 deletions
+22
-22
CMakeLists.txt
benchmark/CMakeLists.txt
+7
-7
CMakeLists.txt
test/CMakeLists.txt
+8
-8
LinqTest.cpp
test/LinqTest.cpp
+6
-6
ToSetTest.cpp
test/ToSetTest.cpp
+1
-1
No files found.
benchmark/CMakeLists.txt
View file @
fe0107e2
...
...
@@ -2,13 +2,13 @@
SET
(
CMAKE_BUILD_TYPE Release
)
SET
(
CMAKE_CXX_STANDARD 11
)
SET
(
CMAKE_CXX_STANDARD_REQUIRED ON
)
SET
(
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Wall -Wextra -Wmissing-include-dirs -Wfloat-equal -Wshadow"
)
SET
(
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Wdouble-promotion -Winit-self -Weffc++"
)
SET
(
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Woverloaded-virtual -Wsign-promo"
)
SET
(
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Wvla -Winvalid-pch -Winline -Wredundant-decls"
)
SET
(
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Wcast-align"
)
SET
(
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Wcast-qual -Wpointer-arith"
)
SET
(
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Wold-style-cast"
)
SET
(
TARGET boolinqbenchmark
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Wall -Wextra -Wmissing-include-dirs -Wfloat-equal -Wshadow"
)
SET
(
TARGET boolinqbenchmark
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Wdouble-promotion -Winit-self -Weffc++"
)
SET
(
TARGET boolinqbenchmark
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Woverloaded-virtual -Wsign-promo"
)
SET
(
TARGET boolinqbenchmark
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Wvla -Winvalid-pch -Winline -Wredundant-decls"
)
SET
(
TARGET boolinqbenchmark
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Wcast-align"
)
SET
(
TARGET boolinqbenchmark
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Wcast-qual -Wpointer-arith"
)
SET
(
TARGET boolinqbenchmark
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Wold-style-cast"
)
INCLUDE_DIRECTORIES
(
${
PROJECT_SOURCE_DIR
}
/externals/benchmark/include
)
...
...
test/CMakeLists.txt
View file @
fe0107e2
# Common variables.
SET
(
CMAKE_CXX_STANDARD 11
)
SET
(
CMAKE_CXX_STANDARD_REQUIRED ON
)
SET
(
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Wall -Wextra -Wmissing-include-dirs -Wfloat-equal -Wshadow"
)
SET
(
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Wdouble-promotion -Winit-self -Weffc++ "
)
SET
(
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Woverloaded-virtual -Wsign-promo"
)
SET
(
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Wvla -Winvalid-pch -Winline -Wredundant-decls"
)
SET
(
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Wcast-align"
)
SET
(
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Wcast-qual -Wpointer-arith"
)
SET
(
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Wold-style-cast"
)
SET
(
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-fprofile-arcs -ftest-coverage"
)
SET
(
TARGET boolinqtest
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Wall -Wextra -Wmissing-include-dirs -Wfloat-equal -Wshadow"
)
SET
(
TARGET boolinqtest
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Wdouble-promotion -Winit-self -Weffc++ "
)
SET
(
TARGET boolinqtest
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Woverloaded-virtual -Wsign-promo"
)
SET
(
TARGET boolinqtest
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Wvla -Winvalid-pch -Winline -Wredundant-decls"
)
SET
(
TARGET boolinqtest
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Wcast-align"
)
SET
(
TARGET boolinqtest
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Wcast-qual -Wpointer-arith"
)
SET
(
TARGET boolinqtest
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-Wold-style-cast"
)
SET
(
TARGET boolinqtest
CMAKE_CXX_FLAGS
"
${
CMAKE_CXX_FLAGS
}
-fprofile-arcs -ftest-coverage"
)
SET
(
CMAKE_SHARED_LINKER_FLAGS
"-fprofile-arcs -ftest-coverage"
)
...
...
test/LinqTest.cpp
View file @
fe0107e2
...
...
@@ -246,19 +246,19 @@ TEST(Linq, Creations)
vec
.
push_back
(
4
);
vec
.
push_back
(
5
);
int
arr
[]
=
{
1
,
2
,
3
,
4
,
5
};
const
int
carr
[]
=
{
1
,
2
,
3
,
4
,
5
};
//
const int carr[] = {1,2,3,4,5};
int
*
ptr
=
static_cast
<
int
*>
(
arr
);
const
int
*
cptr
=
const_cast
<
int
*>
(
arr
);
//
const int * cptr = const_cast<int *>(arr);
auto
dst_vec
=
from
(
vec
);
auto
dst_arr
=
from
(
arr
);
auto
dst_carr
=
from
(
carr
);
//
auto dst_carr = from(carr);
auto
dst_ptr
=
from
<
int
>
(
ptr
,
ptr
+
5
);
auto
dst_cptr
=
from
<
const
int
>
(
cptr
,
cptr
+
5
);
//
auto dst_cptr = from<const int>(cptr, cptr+5);
auto
dst_ptr_length
=
from
<
int
>
(
ptr
,
5
);
auto
dst_cptr_length
=
from
<
const
int
>
(
cptr
,
5
);
//
auto dst_cptr_length = from<const int>(cptr, 5);
auto
dst_vec_iter
=
from
<
int
>
(
vec
.
begin
(),
vec
.
end
());
auto
dst_vec_citer
=
from
<
const
int
>
(
vec
.
cbegin
(),
vec
.
cend
());
//
auto dst_vec_citer = from<const int>(vec.cbegin(), vec.cend());
}
//////////////////////////////////////////////////////////////////////////
...
...
test/ToSetTest.cpp
View file @
fe0107e2
...
...
@@ -18,7 +18,7 @@ TEST(ToSet, Vector2Set)
auto
rng
=
from
(
src
);
auto
dst
=
rng
.
toSet
();
EXPECT_EQ
(
3
,
dst
.
size
());
EXPECT_EQ
(
3
U
,
dst
.
size
());
EXPECT_NE
(
dst
.
end
(),
dst
.
find
(
1
));
EXPECT_NE
(
dst
.
end
(),
dst
.
find
(
2
));
EXPECT_NE
(
dst
.
end
(),
dst
.
find
(
3
));
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment