mercredi 12 juillet 2017

gcc 4.8.4 error: parameter packs not expanded with ‘...’ [duplicate]

I'm getting an error with the following bit of code:

template <typename Container, typename... Ts>
Gen<Container> container(Gen<Ts>... gens) {
  using Strategy = detail::GenericContainerStrategy<Container>;
  detail::ContainerHelper<Container, Strategy> helper{Strategy()};

  return [=](const Random &random, int size) {
    return helper.generate(random, size, gens...);
  };
}

Here is travis build log.

From the log, it says we are using gcc 4.8.4 to build this module. This seems to support parameter packs.

Configuring rapidcheck...

-- The C compiler identification is GNU 4.8.4

-- The CXX compiler identification is GNU 4.8.4

-- Check for working C compiler: /usr/bin/cc

-- Check for working C compiler: /usr/bin/cc -- works

-- Detecting C compiler ABI info

-- Detecting C compiler ABI info - done

-- Detecting C compile features

-- Detecting C compile features - done

-- Check for working CXX compiler: /usr/bin/c++

-- Check for working CXX compiler: /usr/bin/c++ -- works

-- Detecting CXX compiler ABI info

-- Detecting CXX compiler ABI info - done

-- Detecting CXX compile features

-- Detecting CXX compile features - done

-- Configuring done

-- Generating done

So I am unsure of why this build is failing with gcc.

Aucun commentaire:

Enregistrer un commentaire