]> git.proxmox.com Git - ceph.git/blame - ceph/src/boost/libs/phoenix/test/statement/bug5715.cpp
import new upstream nautilus stable release 14.2.8
[ceph.git] / ceph / src / boost / libs / phoenix / test / statement / bug5715.cpp
CommitLineData
7c673cae
FG
1/*=============================================================================
2 Copyright (c) 2005-2007 Dan Marsden
3 Copyright (c) 2005-2007 Joel de Guzman
4 Copyright (c) 2014 John Fletcher
5
6 Distributed under the Boost Software License, Version 1.0. (See accompanying
7 file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
8==============================================================================*/
9
10// Check for Bug5715
11
12#include <boost/phoenix/statement/sequence.hpp>
13#include <boost/phoenix/bind.hpp>
14
92f5a8d4 15#include <boost/core/lightweight_test.hpp>
7c673cae
FG
16
17namespace test
18{
19 int x = 0;
20 int y = 0;
21 int z = 0;
22
23 void f() { ++x; ++y; }
24 void g() { --x; ++z; }
25
26}
27int main()
28{
29 (
30 boost::phoenix::bind(test::f),
31 boost::phoenix::bind(test::g)
32 )();
33 BOOST_TEST(test::x == 0);
34 BOOST_TEST(test::y == 1);
35 BOOST_TEST(test::z == 1);
92f5a8d4 36 return boost::report_errors();
7c673cae 37}