summaryrefslogtreecommitdiffstats
path: root/src/corelib/doc
diff options
context:
space:
mode:
authorKai Koehne <kai.koehne@digia.com>2014-01-10 15:42:19 +0100
committerThe Qt Project <gerrit-noreply@qt-project.org>2014-02-14 08:45:00 +0100
commit85e576535c9c39756ecaddefa245f71fb35b8589 (patch)
treeb5f9333825c3d1eb901cbddb67101a29d486202d /src/corelib/doc
parentb648f11227054b1e029c202c2a996f359335a86b (diff)
Let Q_DECLARE_LOGGING_CATEGORY and Q_LOGGING_CATEGORY return a const reference
In general QLoggingCategory should be treated as a const object that's configured by the backend. The only legitimate place where user code should call setEnabled is in a CategoryFilter ... [ChangeLog][QtCore][Logging] Make Q_LOGGING_CATEGORY and Q_DECLARE_LOGGING_CATEGORY return a const object. Change-Id: I6140442ab48286e05cd3b55064a502bbe6dfb16a Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'src/corelib/doc')
-rw-r--r--src/corelib/doc/snippets/code/qlogging/qlogging.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/corelib/doc/snippets/code/qlogging/qlogging.cpp b/src/corelib/doc/snippets/code/qlogging/qlogging.cpp
index d3b9e1fd14..ff5ce23eff 100644
--- a/src/corelib/doc/snippets/code/qlogging/qlogging.cpp
+++ b/src/corelib/doc/snippets/code/qlogging/qlogging.cpp
@@ -54,5 +54,5 @@
//! [1]
//! [2]
- QLoggingCategory &category();
+ const QLoggingCategory &category();
//! [2]