]>
git.proxmox.com Git - ceph.git/blob - ceph/src/boost/libs/math/test/compile_test/catmull_rom_incl_test.cpp
1 // Copyright Nick Thompson 2018.
2 // Use, modification and distribution are subject to the
3 // Boost Software License, Version 1.0. (See accompanying file
4 // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
6 // Basic sanity check that header <boost/math/interpolators/catmull_rom.hpp>
7 // #includes all the files that it needs to.
9 #include <boost/math/interpolators/catmull_rom.hpp>
11 // Note this header includes no other headers, this is
12 // important if this test is to be meaningful:
14 #include "test_compile_result.hpp"
16 void compile_and_link_test()
18 std::vector
<double> p0
{0.1, 0.2, 0.3};
19 std::vector
<double> p1
{0.2, 0.3, 0.4};
20 std::vector
<double> p2
{0.3, 0.4, 0.5};
21 std::vector
<double> p3
{0.4, 0.5, 0.6};
22 std::vector
<double> p4
{0.5, 0.6, 0.7};
23 std::vector
<double> p5
{0.6, 0.7, 0.8};
24 std::vector
<std::vector
<double>> v
{p0
, p1
, p2
, p3
, p4
, p5
};
25 boost::math::catmull_rom
<std::vector
<double>> cat(std::move(v
));
26 check_result
<std::vector
<double>>(cat(0.0));
27 check_result
<std::vector
<double>>(cat
.prime(0.0));