LeechCraft
0.6.70-18450-gabe19ee3b0
Modular cross-platform feature rich live environment.
Toggle main menu visibility
Loading...
Searching...
No Matches
debugprinters.h
Go to the documentation of this file.
1
/**********************************************************************
2
* LeechCraft - modular cross-platform feature rich internet client.
3
* Copyright (C) 2006-2014 Georg Rudoy
4
*
5
* Distributed under the Boost Software License, Version 1.0.
6
* (See accompanying file LICENSE or copy at https://www.boost.org/LICENSE_1_0.txt)
7
**********************************************************************/
8
9
#pragma once
10
11
#include "
sllconfig.h
"
12
#include <QDebug>
13
#include <QDomDocument>
14
#include "
either.h
"
15
16
UTIL_SLL_API
QDebug
operator<<
(QDebug,
const
QDomDocument::ParseResult&);
17
18
namespace
LC::Util
19
{
20
template
<
typename
T>
21
concept
QDebuggable
=
requires
(T t, QDebug out) { out << t; };
22
23
template
<QDebuggable L, QDebuggable R>
24
QDebug
operator<<
(QDebug out,
const
Either<L, R>
& either)
25
{
26
QDebugStateSaver saver { out };
27
Visit
(either,
28
[&out] (
const
L& l) { out.nospace () <<
"L { "
<< l <<
" }"
; },
29
[&out] (
const
R& r) { out.nospace () <<
"R { "
<< r <<
" }"
; });
30
return
out;
31
}
32
}
LC::Util::Either
Definition
either.h:33
LC::Util::QDebuggable
Definition
debugprinters.h:21
operator<<
UTIL_SLL_API QDebug operator<<(QDebug, const QDomDocument::ParseResult &)
Definition
debugprinters.cpp:12
LC::Util
Definition
icoreproxy.h:34
LC::Util::Visit
auto Visit(const Either< Left, Right > &either, Args &&... args)
Definition
either.h:180
LC::Util::operator<<
QDebug operator<<(QDebug dbg, const CtString< N, Char > &str)
Definition
ctstringutils.h:113
either.h
sllconfig.h
UTIL_SLL_API
#define UTIL_SLL_API
Definition
sllconfig.h:16
src
util
sll
debugprinters.h
Generated by
1.17.0