aboutsummaryrefslogtreecommitdiff
path: root/development/uncrustify
diff options
context:
space:
mode:
authorZhu Qun-Ying <zhu.qunying@gmail.com>2020-05-25 16:13:22 -0700
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2020-05-26 10:14:32 +0700
commit89ac9f15fe6e1a1b2b21c70594e23950e5ef5511 (patch)
treede36fc3231dc279f4ca1e9c0177e7ba4d0ff3f4a /development/uncrustify
parent3b7e450ce34f21642918a0bd75f252e1ca14d23a (diff)
development/uncrustify: Updated for version 0.71.0
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'development/uncrustify')
-rw-r--r--development/uncrustify/nl_func_leave_one_liners.patch104
-rw-r--r--development/uncrustify/uncrustify.SlackBuild5
-rw-r--r--development/uncrustify/uncrustify.info6
3 files changed, 5 insertions, 110 deletions
diff --git a/development/uncrustify/nl_func_leave_one_liners.patch b/development/uncrustify/nl_func_leave_one_liners.patch
deleted file mode 100644
index 60c43119cb29..000000000000
--- a/development/uncrustify/nl_func_leave_one_liners.patch
+++ /dev/null
@@ -1,104 +0,0 @@
-From 06822aa69bf460b5ef0363f2a0cf69ec7a426bda Mon Sep 17 00:00:00 2001
-From: Guy Maurel <g.maurel@agwest.de>
-Date: Fri, 29 Nov 2019 18:04:25 +0100
-Subject: nl_func_leave_one_liners is now completed
-
-Ref. #2561
-
-diff --git a/src/newlines.cpp b/src/newlines.cpp
-index a7db6181..576cd874 100644
---- a/src/newlines.cpp
-+++ b/src/newlines.cpp
-@@ -2782,12 +2782,30 @@ static void newline_func_def_or_call(chunk_t *start)
-
- if (tmp_next != nullptr && tmp_next->type != CT_FUNC_CLASS_DEF)
- {
-- bool is_proto = ( tmp->parent_type == CT_FUNC_PROTO
-- || tmp->parent_type == CT_FUNC_CLASS_PROTO);
-- iarf_e a = (is_proto) ?
-- options::nl_func_proto_type_name() :
-- (options::nl_func_leave_one_liners()) ? // Issue #1511
-- IARF_IGNORE : options::nl_func_type_name();
-+ chunk_t *closing = chunk_skip_to_match(tmp);
-+ chunk_t *brace = chunk_get_next_ncnl(closing);
-+ iarf_e a; // Issue #2561
-+
-+ if ( tmp->parent_type == CT_FUNC_PROTO
-+ || tmp->parent_type == CT_FUNC_CLASS_PROTO)
-+ {
-+ // proto
-+ a = options::nl_func_proto_type_name();
-+ }
-+ else
-+ {
-+ // def
-+
-+ if ( options::nl_func_leave_one_liners()
-+ && brace->flags.test(PCF_ONE_LINER)) // Issue #1511
-+ {
-+ a = IARF_IGNORE;
-+ }
-+ else
-+ {
-+ a = options::nl_func_type_name();
-+ }
-+ }
-
- if ( tmp->flags.test(PCF_IN_CLASS)
- && (options::nl_func_type_name_class() != IARF_IGNORE))
-diff --git a/tests/config/Issue_2561.cfg b/tests/config/Issue_2561.cfg
-new file mode 100644
-index 00000000..03a40504
---- /dev/null
-+++ b/tests/config/Issue_2561.cfg
-@@ -0,0 +1,5 @@
-+sp_func_def_paren = force
-+indent_columns = 3
-+nl_func_leave_one_liners = true
-+nl_func_type_name = force
-+mod_add_long_function_closebrace_comment = 1
-diff --git a/tests/cpp.test b/tests/cpp.test
-index 77797aed..39c7e421 100644
---- a/tests/cpp.test
-+++ b/tests/cpp.test
-@@ -96,6 +96,7 @@
- 30085 nSolve.cfg cpp/align_class.cpp
- 30086 align_class-constr.cfg cpp/align_class-constr.cpp
- 30087 Issue_1511.cfg cpp/Issue_1511.cpp
-+30088 Issue_2561.cfg cpp/Issue_2561.cpp
-
- 30090 bug_488.cfg cpp/bug_488.cpp
- 30091 bug_472.cfg cpp/bug_472.cpp
-diff --git a/tests/expected/cpp/30088-Issue_2561.cpp b/tests/expected/cpp/30088-Issue_2561.cpp
-new file mode 100644
-index 00000000..aa566966
---- /dev/null
-+++ b/tests/expected/cpp/30088-Issue_2561.cpp
-@@ -0,0 +1,11 @@
-+#include <stdio.h>
-+
-+int getFoo () { return foo; }
-+
-+int
-+main (int argc, char *argv[])
-+{
-+ printf("hello world!\n");
-+
-+ return 0;
-+} // main
-diff --git a/tests/input/cpp/Issue_2561.cpp b/tests/input/cpp/Issue_2561.cpp
-new file mode 100644
-index 00000000..15232fc4
---- /dev/null
-+++ b/tests/input/cpp/Issue_2561.cpp
-@@ -0,0 +1,10 @@
-+#include <stdio.h>
-+
-+int getFoo() { return foo; }
-+
-+int main (int argc, char *argv[])
-+{
-+ printf("hello world!\n");
-+
-+ return 0;
-+}
diff --git a/development/uncrustify/uncrustify.SlackBuild b/development/uncrustify/uncrustify.SlackBuild
index 3695cc75b80a..7b170d05ade6 100644
--- a/development/uncrustify/uncrustify.SlackBuild
+++ b/development/uncrustify/uncrustify.SlackBuild
@@ -5,8 +5,8 @@
# Written by Aleksandar Samardzic <asamardzic@gmail.com>
PRGNAM=uncrustify
-VERSION=${VERSION:-0.70.1}
-BUILD=${BUILD:-2}
+VERSION=${VERSION:-0.71.0}
+BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
if [ -z "$ARCH" ]; then
@@ -46,7 +46,6 @@ find -L . \
-o -perm 511 \) -exec chmod 755 {} \; -o \
\( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
-o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
-patch -p1 < $CWD/nl_func_leave_one_liners.patch
mkdir -p build
cd build
cmake \
diff --git a/development/uncrustify/uncrustify.info b/development/uncrustify/uncrustify.info
index d9b16ee9c986..4c5514fb7e21 100644
--- a/development/uncrustify/uncrustify.info
+++ b/development/uncrustify/uncrustify.info
@@ -1,8 +1,8 @@
PRGNAM="uncrustify"
-VERSION="0.70.1"
+VERSION="0.71.0"
HOMEPAGE="http://uncrustify.sourceforge.net/"
-DOWNLOAD="https://github.com/uncrustify/uncrustify/archive/uncrustify-0.70.1/uncrustify-uncrustify-0.70.1.tar.gz"
-MD5SUM="7b018fb343615bdb0c8c1143b89b61da"
+DOWNLOAD="https://github.com/uncrustify/uncrustify/archive/uncrustify-0.71.0/uncrustify-uncrustify-0.71.0.tar.gz"
+MD5SUM="748482d4c16e2de966505c7e3829d925"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
REQUIRES=""