]> git.proxmox.com Git - ceph.git/blame - ceph/src/boost/boost/log/expressions/predicates/is_debugger_present.hpp
update ceph source to reef 18.1.2
[ceph.git] / ceph / src / boost / boost / log / expressions / predicates / is_debugger_present.hpp
CommitLineData
7c673cae 1/*
1e59de90 2 * Copyright Andrey Semashev 2007 - 2021.
7c673cae
FG
3 * Distributed under the Boost Software License, Version 1.0.
4 * (See accompanying file LICENSE_1_0.txt or copy at
5 * http://www.boost.org/LICENSE_1_0.txt)
6 */
7/*!
8 * \file is_debugger_present.hpp
9 * \author Andrey Semashev
10 * \date 05.12.2012
11 *
12 * The header contains implementation of the \c is_debugger_present predicate in template expressions.
13 */
14
15#ifndef BOOST_LOG_EXPRESSIONS_PREDICATES_IS_DEBUGGER_PRESENT_HPP_INCLUDED_
16#define BOOST_LOG_EXPRESSIONS_PREDICATES_IS_DEBUGGER_PRESENT_HPP_INCLUDED_
17
18#include <boost/log/detail/config.hpp>
19
20#ifdef BOOST_HAS_PRAGMA_ONCE
21#pragma once
22#endif
23
24#if defined(BOOST_WINDOWS)
25
26#include <boost/phoenix/core/terminal.hpp> // this is needed to be able to include this header alone, Boost.Phoenix blows up without it
27#include <boost/phoenix/function/adapt_callable.hpp>
28#include <boost/log/detail/header.hpp>
29
7c673cae
FG
30namespace boost {
31
32BOOST_LOG_OPEN_NAMESPACE
33
34namespace expressions {
35
36namespace aux {
37
38struct is_debugger_present
39{
40 typedef bool result_type;
41
1e59de90 42 BOOST_LOG_API result_type operator() () const;
7c673cae
FG
43};
44
45} // namespace aux
46
47#ifndef BOOST_LOG_DOXYGEN_PASS
48
49BOOST_PHOENIX_ADAPT_CALLABLE_NULLARY(is_debugger_present, aux::is_debugger_present)
50
51#else
52
53/*!
54 * The function generates a filter that will check whether the logger is attached to the process
55 */
56unspecified is_debugger_present();
57
58#endif
59
60} // namespace expressions
61
62BOOST_LOG_CLOSE_NAMESPACE // namespace log
63
64} // namespace boost
65
66#include <boost/log/detail/footer.hpp>
67
68#endif // BOOST_WINDOWS
69
70#endif // BOOST_LOG_EXPRESSIONS_PREDICATES_IS_DEBUGGER_PRESENT_HPP_INCLUDED_