Skip to content

Commit

Permalink
Require opt-out for using QLinkedList
Browse files Browse the repository at this point in the history
Now that all QLinkedList uses are removed from Qt, make sure
QT_NO_LINKED_LIST is set by default for Qt modules, so new
modules don't need to explicitly specify it in their
.qmake.conf.

Modules can still opt out of the QLinkedList ban by adding
   DEFINES -= QT_NO_LINKED_LIST
to their .qmake.conf.

Change-Id: I34b7ab1c009795649bb7b4f1e7493556eafadd5a
Reviewed-by: Volker Hilsheimer <[email protected]>
Reviewed-by: Lars Knoll <[email protected]>
  • Loading branch information
marc-kdab committed Aug 7, 2019
1 parent 1563c38 commit 213f7d1
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
1 change: 0 additions & 1 deletion .qmake.conf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ load(qt_build_config)
CONFIG += warning_clean

DEFINES += QT_NO_JAVA_STYLE_ITERATORS
DEFINES += QT_NO_LINKED_LIST

QT_SOURCE_TREE = $$PWD
QT_BUILD_TREE = $$shadowed($$PWD)
Expand Down
4 changes: 4 additions & 0 deletions mkspecs/features/qt_build_config.prf
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,10 @@ macos: CONFIG += testcase_no_bundle
# Override MinGW's definition in _mingw.h
mingw: DEFINES += WINVER=0x0601 _WIN32_WINNT=0x0601

# By default, the following features should not be used in Qt's own
# implementation, so declare them invisible to Qt modules.
DEFINES += QT_NO_LINKED_LIST # QLinkedList

defineTest(qtBuildPart) {
bp = $$eval($$upper($$section(_QMAKE_CONF_, /, -2, -2))_BUILD_PARTS)
isEmpty(bp): bp = $$QT_BUILD_PARTS
Expand Down

0 comments on commit 213f7d1

Please sign in to comment.