"Dockerfile" did not exist on "7508c87d38797d994c4ba7f8ee95174a7bf41aa6"
Commit 592f7372 authored by Paul's avatar Paul
Browse files

Formatting

parent 31291843
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
namespace migraph { namespace migraph {
template<class Range, class Iterator> template <class Range, class Iterator>
std::ptrdiff_t bidistance(const Range& r, Iterator start, Iterator last) std::ptrdiff_t bidistance(const Range& r, Iterator start, Iterator last)
{ {
auto start_forward = start; auto start_forward = start;
...@@ -16,14 +16,15 @@ std::ptrdiff_t bidistance(const Range& r, Iterator start, Iterator last) ...@@ -16,14 +16,15 @@ std::ptrdiff_t bidistance(const Range& r, Iterator start, Iterator last)
while(start_forward != last and start_backwards != last) while(start_forward != last and start_backwards != last)
{ {
n++; n++;
if(start_forward != r.end()) start_forward++; if(start_forward != r.end())
if(start_backwards != r.begin()) start_backwards--; start_forward++;
if(start_backwards != r.begin())
start_backwards--;
} }
if(start_forward == last) if(start_forward == last)
return n; return n;
else else
return -n; return -n;
} }
void dead_code_elimination::apply(program& p) const void dead_code_elimination::apply(program& p) const
......
Markdown is supported
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