Commit c5f2f034 authored by Bouke van der Bijl's avatar Bouke van der Bijl
Browse files

lemon-graph: fix C++17 build

parent 91414c63
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -18,6 +18,11 @@ stdenv.mkDerivation rec {
  # error: no viable conversion from ...
  doCheck = !stdenv.isDarwin;

  patches = [
    # error: ISO C++17 does not allow 'register' storage class specifier
    ./remove-register.patch
  ];

  meta = with lib; {
    homepage = "https://lemon.cs.elte.hu/trac/lemon";
    description = "Efficient library for combinatorial optimization tasks on graphs and networks";
+15 −0
Original line number Diff line number Diff line
diff --git a/lemon/random.h b/lemon/random.h
index 8de74ede8a..f9861f3916 100644
--- a/lemon/random.h
+++ b/lemon/random.h
@@ -249,8 +249,8 @@ namespace lemon {
 
         current = state + length;
 
-        register Word *curr = state + length - 1;
-        register long num;
+        Word *curr = state + length - 1;
+        long num;
 
         num = length - shift;
         while (num--) {