Skip to content
Snippets Groups Projects
Commit 82deb6b4 authored by p-hamann's avatar p-hamann
Browse files

Prefer inline for simple methods

parent c74b50bc
Branches
1 merge request!9Perf optimization
...@@ -152,7 +152,3 @@ void edmonds_karp::run() { ...@@ -152,7 +152,3 @@ void edmonds_karp::run() {
}; };
int edmonds_karp::get_max_flow() const {
return flow_value_;
};
...@@ -120,6 +120,3 @@ void push_relabel::run() { ...@@ -120,6 +120,3 @@ void push_relabel::run() {
} }
int push_relabel::get_max_flow() const {
return flow_value_;
}
...@@ -66,7 +66,9 @@ public: ...@@ -66,7 +66,9 @@ public:
* *
* @return The maximum flow value * @return The maximum flow value
*/ */
int get_max_flow() const; int get_max_flow() const {
return flow_value_;
};
}; };
#endif /* EDMONDSKARP_H_ */ #endif /* EDMONDSKARP_H_ */
...@@ -53,7 +53,9 @@ public: ...@@ -53,7 +53,9 @@ public:
* Returns the value of the maximum flow from sources to sinks. * Returns the value of the maximum flow from sources to sinks.
* @return The maximum flow value * @return The maximum flow value
*/ */
int get_max_flow() const; int get_max_flow() const {
return flow_value_;
};
}; };
#endif /* PUSHRELABEL_H_ */ #endif /* PUSHRELABEL_H_ */
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment