Intel® C++ Compiler
Community support and assistance for creating C++ code that runs on platforms based on Intel® processors.
7956 Discussions

valid c++ variadic code causes segfault with icc

rnickb
Beginner
424 Views

This code compiles fine with gcc and clang, but causes a segfault with icc 2016 (used -std=c++14)

 

#include <tuple>
#include <type_traits>
#include <utility>

template<class... Tx>
void f(const std::tuple<Tx...>& t,
  std::enable_if_t<Tx() || true, int>... indexes) {
}

int main() {
  auto t = std::make_tuple(3, 4.0);
  f(t, 1 ,2);
  return 0;
}

 

0 Kudos
2 Replies
KitturGanesh
Employee
424 Views

Hi,
I've filed this issue with the developers and will update you as soon as the release with the fix is out, appreciate much.
​_Kittur

0 Kudos
KitturGanesh
Employee
424 Views

Hi,
This issue is fixed in the latest product release (16.0) which you can download from the https://registrationcenter.intel.com, thx.

_Kittur

0 Kudos
Reply