[PATCH] fix: use values that are representable as double in test
authorAnsgar Burchardt <ansgar.burchardt@tu-dresden.de>
Mon, 25 Dec 2023 22:40:36 +0000 (23:40 +0100)
committerMarkus Blatt <markus@dr-blatt.de>
Thu, 10 Oct 2024 14:59:54 +0000 (16:59 +0200)
commit3c6146536f2086ef04d475a14aa3f8355c13e25e
tree269a08e7ba77abbbebe6eac472067dfb4278225a
parente66fc9b4895e917a117eb36003ac0515cdcbb57c
[PATCH] fix: use values that are representable as double in test

From f61fb0dbc9b41b2661a3b481a056fd006a238495 Mon Sep 17 00:00:00 2001
Origin: vendor, https://gitlab.dune-project.org/core/dune-common/-/merge_requests/1327

Values like 0.1 are not representable as a double which can result in
problems, for example:

```
[...]/dune/common/test/hybridutilitiestest.cc:114:43: error: static assertion failed: Wrong compile time sum!
  114 |   static_assert(sum(numberTupleConstexpr) == 5.1, "Wrong compile time sum!");
      |                 ~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~
[...]/dune/common/test/hybridutilitiestest.cc:114:43: note: the comparison reduces to ‘(5.09999999999999964473e+0l == 5.09999999999999999991e+0l)’
```

with [gcc 13.2.0 on i386][1].

  [1]: https://buildd.debian.org/status/fetch.php?pkg=dune-common&arch=i386&ver=2.9.0-4&stamp=1703267709&raw=0

Gbp-Pq: Name 0001-fix-use-values-that-are-representable-as-double-in-t.patch
dune/common/test/hybridutilitiestest.cc