Advertisement
Guest User

static assertion fail

a guest
Apr 24th, 2022
68
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.74 KB | None | 0 0
  1. satacker@ubuntu:~/wg21_p2300_std_execution/build$ clang++-12 -std=c++2b ../examples/schedulers/inline_scheduler.cpp -I../include/ -fcoroutines-ts -lpthread -stdlib=libc++
  2. ../examples/schedulers/inline_scheduler.cpp:10:17: error: static_assert expression is not an integral constant expression
  3. static_assert(k==std::execution::forward_progress_guarantee::weakly_parallel);
  4. ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  5. ../examples/schedulers/inline_scheduler.cpp:10:17: note: read of non-const variable 'k' is not allowed in a constant expression
  6. ../examples/schedulers/inline_scheduler.cpp:8:8: note: declared here
  7. auto k = std::execution::get_forward_progress_guarantee(std::ref(s));
  8. ^
  9. 1 error generated.
  10.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement