Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Tiago Peixoto
graph-tool
Commits
c9e4bfe8
Commit
c9e4bfe8
authored
Nov 13, 2010
by
Tiago Peixoto
Browse files
Fix compilation warnings
parent
6758e857
Changes
4
Hide whitespace changes
Inline
Side-by-side
src/boost-workaround/boost/graph/isomorphism.hpp
View file @
c9e4bfe8
...
...
@@ -21,6 +21,17 @@
#include <boost/graph/iteration_macros.hpp>
#endif
// redefine this locally to avoid a stupid compilation warning
#undef BGL_FORALL_ADJ_T
#define BGL_FORALL_ADJ_T(UNAME, VNAME, GNAME, GraphType) \
for (std::pair<typename boost::graph_traits<GraphType>::adjacency_iterator, \
typename boost::graph_traits<GraphType>::adjacency_iterator> BGL_RANGE(__LINE__) = adjacent_vertices(UNAME, GNAME); \
BGL_FIRST(__LINE__) != BGL_LAST(__LINE__); BGL_FIRST(__LINE__) = BGL_LAST(__LINE__)) \
for (typename boost::graph_traits<GraphType>::vertex_descriptor VNAME = 0; \
BGL_FIRST(__LINE__) != BGL_LAST(__LINE__) ? (VNAME = *BGL_FIRST(__LINE__), true) : false; \
++BGL_FIRST(__LINE__))
namespace
boost
{
namespace
detail
{
...
...
src/graph/generation/graph_lattice.hh
View file @
c9e4bfe8
...
...
@@ -64,7 +64,7 @@ struct get_lattice
bool
periodic_boundary
)
const
{
int
N
=
1
;
for
(
in
t
i
=
0
;
i
<
shape
.
size
();
++
i
)
for
(
size_
t
i
=
0
;
i
<
shape
.
size
();
++
i
)
N
*=
shape
[
i
];
for
(
int
i
=
0
;
i
<
N
;
++
i
)
add_vertex
(
g
);
...
...
src/graph/stats/graph_average.hh
View file @
c9e4bfe8
...
...
@@ -71,8 +71,8 @@ struct get_average
void
operator
()(
Graph
&
g
,
DegreeSelector
deg
)
const
{
typedef
typename
DegreeSelector
::
value_type
value_type
;
long
double
a
,
aa
;
size_t
count
;
long
double
a
=
0
,
aa
=
0
;
size_t
count
=
0
;
AverageTraverse
traverse
;
int
i
,
N
=
num_vertices
(
g
);
...
...
src/graph/util/graph_search.hh
View file @
c9e4bfe8
...
...
@@ -44,8 +44,8 @@ bool operator<=(const vector<ValueType>& v1, const vector<ValueType>& v2)
return
true
;
if
(
v1
.
size
()
>
v2
.
size
())
return
false
;
long
double
d1
,
d2
;
for
(
size_t
i
;
i
<
v1
.
size
();
++
i
)
long
double
d1
=
0
,
d2
=
0
;
for
(
size_t
i
=
0
;
i
<
v1
.
size
();
++
i
)
{
d1
+=
v1
[
i
]
*
v1
[
i
];
d2
+=
v2
[
i
]
*
v2
[
i
];
...
...
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