]> granicus.if.org Git - graphviz/commitdiff
tests: fix missing #include
authorMatthew Fernandez <matthew.fernandez@gmail.com>
Fri, 21 Oct 2022 15:06:14 +0000 (08:06 -0700)
committerMatthew Fernandez <matthew.fernandez@gmail.com>
Wed, 2 Nov 2022 01:55:55 +0000 (18:55 -0700)
The default toolchain on Ubuntu 22.10 comes with a slightly more pedantic header
layout:

  [ 87%] Building CXX object tests/CMakeFiles/test_common.dir/svg_element.cpp.o
  tests/svg_element.cpp: In member function 'SVG::SVGRect
    SVG::SVGElement::outline_bbox(bool)':
  tests/svg_element.cpp:287:29: error: 'all_of' is not a member of 'std'
    287 |     auto is_vertical = std::all_of(
        |                             ^~~~~~
  tests/svg_element.cpp:290:31: error: 'all_of' is not a member of 'std'
    290 |     auto is_horizontal = std::all_of(
        |                               ^~~~~~

tests/svg_element.cpp

index 5e1b2d9d5620036dd527531bbb67653d17580d3d..388ea3922117b25c4a48985c5ca4fc70645c0644 100644 (file)
@@ -1,3 +1,4 @@
+#include <algorithm>
 #include <cassert>
 #include <cmath>
 #include <limits>