summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--recipes-qt/qt5/qt5-creator/0001-clangformat-AllowShortIfStatementsOnASingleLine-is-n.patch36
-rw-r--r--recipes-qt/qt5/qt5-creator_git.bb1
2 files changed, 37 insertions, 0 deletions
diff --git a/recipes-qt/qt5/qt5-creator/0001-clangformat-AllowShortIfStatementsOnASingleLine-is-n.patch b/recipes-qt/qt5/qt5-creator/0001-clangformat-AllowShortIfStatementsOnASingleLine-is-n.patch
new file mode 100644
index 00000000..1bc3632d
--- /dev/null
+++ b/recipes-qt/qt5/qt5-creator/0001-clangformat-AllowShortIfStatementsOnASingleLine-is-n.patch
@@ -0,0 +1,36 @@
1From 453c075b67b9d9254bf7331e1e3be287f240a9e0 Mon Sep 17 00:00:00 2001
2From: Khem Raj <raj.khem@gmail.com>
3Date: Tue, 3 Sep 2019 13:31:12 -0700
4Subject: [PATCH] clangformat: AllowShortIfStatementsOnASingleLine is not
5 boolean anymore
6
7https://reviews.llvm.org/D59087 has implemented multiple states for AllowShortIfStatementsOnASingleLine
8
9Fixes
10../../../../git/src/plugins/clangformat/clangformatutils.cpp:63:49: error: assigning to 'clang::format::FormatStyle::ShortIfStyle' from incompatible type 'bool'
11 style.AllowShortIfStatementsOnASingleLine = false;
12 ^~~~~
13
14Upstream-Status: Pending
15
16Signed-off-by: Khem Raj <raj.khem@gmail.com>
17---
18 src/plugins/clangformat/clangformatutils.cpp | 2 +-
19 1 file changed, 1 insertion(+), 1 deletion(-)
20
21diff --git a/src/plugins/clangformat/clangformatutils.cpp b/src/plugins/clangformat/clangformatutils.cpp
22index 09a3150c89..7d8a95ae18 100644
23--- a/src/plugins/clangformat/clangformatutils.cpp
24+++ b/src/plugins/clangformat/clangformatutils.cpp
25@@ -60,7 +60,7 @@ static clang::format::FormatStyle qtcStyle()
26 style.AllowShortBlocksOnASingleLine = false;
27 style.AllowShortCaseLabelsOnASingleLine = false;
28 style.AllowShortFunctionsOnASingleLine = FormatStyle::SFS_Inline;
29- style.AllowShortIfStatementsOnASingleLine = false;
30+ style.AllowShortIfStatementsOnASingleLine = FormatStyle::SIS_Never;
31 style.AllowShortLoopsOnASingleLine = false;
32 style.AlwaysBreakAfterReturnType = FormatStyle::RTBS_None;
33 style.AlwaysBreakBeforeMultilineStrings = false;
34--
352.23.0
36
diff --git a/recipes-qt/qt5/qt5-creator_git.bb b/recipes-qt/qt5/qt5-creator_git.bb
index 107fee53..a3960042 100644
--- a/recipes-qt/qt5/qt5-creator_git.bb
+++ b/recipes-qt/qt5/qt5-creator_git.bb
@@ -25,6 +25,7 @@ PV = "4.9.2+git${SRCPV}"
25# 4.9.2.meta-qt5.1 25# 4.9.2.meta-qt5.1
26SRC_URI = " \ 26SRC_URI = " \
27 git://code.qt.io/qt-creator/qt-creator.git;branch=4.9 \ 27 git://code.qt.io/qt-creator/qt-creator.git;branch=4.9 \
28 file://0001-clangformat-AllowShortIfStatementsOnASingleLine-is-n.patch \
28" 29"
29SRC_URI_append_libc-musl = " file://0001-Link-with-libexecinfo-on-musl.patch" 30SRC_URI_append_libc-musl = " file://0001-Link-with-libexecinfo-on-musl.patch"
30 31