Skip to content
Snippets Groups Projects

Test complex<T> for floating point T only

Merged Elias Pipping requested to merge (removed):feature/FS1726-complex-for-fp-only into master

The standard leaves (the effect of instantiating) complex for more general T unspecified.

While we're at it, kill duplicate tests and add long double to the list.

This fixes bug flyspray/FS#1726 (closed): Now also with clang 3.7 and libstdc++ 4.9.2 on Debian 8.2, the test fvectortest can be compiled again.

Merge request reports

Merged by avatar (Apr 18, 2025 9:19am UTC)

Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
379 473 FieldVectorTest<int, 3>();
380 474 FieldVectorTest<float, 3>();
381 475 FieldVectorTest<double, 3>();
382 FieldVectorTest<int, 1>();
383 FieldVectorTest<double, 1>();
476 FieldVectorTest<long double, 3>();
  • 290 316 assert(std::abs(result-ct(2)*length*I)<= myEps);
    291 317
    292 318 }
    319 };
    320
    321 // scalar ordering doesn't work for complex numbers
    322 template <class rt, int d>
    323 struct DotProductTest<rt, d, false>
    324 {
    325 DotProductTest() {
    326 DUNE_UNUSED const rt myEps = Epsilon<rt>::value();
    • Author Developer

      Is it correct to use DUNE_UNUSED with variables that are only used inside assert? I only copied this line but it made me wonder...

      Update: Never mind. I answered my own question and used it to write 5b618064

      Edited by Elias Pipping
  • Elias Pipping mentioned in merge request !15 (merged)

    mentioned in merge request !15 (merged)

  • mentioned in commit 627fc0b0

  • Christian Engwer Status changed to merged

    Status changed to merged

  • mentioned in issue #17 (closed)

  • mentioned in commit 9b55a240

  • Mentioned in commit 627fc0b0

  • Please register or sign in to reply
    Loading