Received: (at submit) by debbugs.gnu.org; 2 Jul 2018 23:32:24 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Mon Jul 02 19:32:24 2018 Received: from localhost ([127.0.0.1]:44160 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1fa8Iw-0007Dq-Ae for submit <at> debbugs.gnu.org; Mon, 02 Jul 2018 19:32:24 -0400 Received: from md5i.com ([75.151.244.229]:43626) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <mwd@HIDDEN>) id 1fa8Iu-0007Di-Em for submit <at> debbugs.gnu.org; Mon, 02 Jul 2018 19:32:20 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=md5i.com; s=dkim; h=Content-Type:MIME-Version:Message-ID:Date:Subject:To:From:Sender: Reply-To:Cc:Content-Transfer-Encoding:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: In-Reply-To:References:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=x83t8EmKcev2U7HO39vDfI+fm0epfKDo4xY87e/jpJI=; b=X7rWs06XBc37km2WQTe/46jCCp Is785OIDWm3L02KhPff+RBBAPnPQmqX7UGFXLcxkG4EsqnYFjqD5E+VMeFpWY2dUjLGaefLFP6HeI w/vKOZ8ITCURFjxmjpTx3Nm1E; Received: from md5i by md5i.com with local (Exim 4.91) (envelope-from <mwd@HIDDEN>) id 1fa8It-0002y7-Uu for submit <at> debbugs.gnu.org; Mon, 02 Jul 2018 19:32:19 -0400 From: Michael Welsh Duggan <mwd@HIDDEN> To: submit <at> debbugs.gnu.org Subject: CC Mode 5.33.1 (C++//l); function-try-block handling suboptimal X-Debbugs-Package: cc-mode Date: Mon, 02 Jul 2018 19:32:19 -0400 Message-ID: <87k1qduscc.fsf@HIDDEN> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.0 (-) --=-=-= Content-Type: text/plain Handling (indentation) of the function-try-block in C++ is sub-optimal. I have included a simple example. See <URL:https://en.cppreference.com/w/cpp/language/function-try-block> for more information about function-try-block. --=-=-= Content-Type: text/x-c\+\+ Content-Disposition: inline struct Foo { int x; Foo() : x(0) // member-init-intro (correct) { // inclass, inline-open } // inline-close }; struct Bar { int x; Bar() try : x(0) // substatement (incorrect) { // substatement-open (incorrect, maybe?) } // incline-close catch (...) { } }; // Reasonable indentation int foo() try { } catch (...) { } // Bad indentation int bar() try { } catch (...) { } --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Emacs : GNU Emacs 27.0.50 (build 4, x86_64-pc-linux-gnu, X toolkit) of 2018-06-24 Package: CC Mode 5.33.1 (C++//l) Buffer Style: Pharos c-emacs-features: (pps-extended-state col-0-paren posix-char-classes gen-st= ring-delim gen-comment-delim syntax-properties 1-bit) current state: =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D (setq c-basic-offset 2 c-comment-only-line-offset 0 c-indent-comment-alist '((anchored-comment column . 0) (end-block space . = 1) (cpp-end-block space . 2)) c-indent-comments-syntactically-p nil c-block-comment-prefix "" c-comment-prefix-regexp '((pike-mode . "//+!?\\|\\**") (awk-mode . "#+") (other . "//+\\|\\**")) c-doc-comment-style '((java-mode . javadoc) (pike-mode . autodoc) (c-mode . gtkdoc)) c-cleanup-list '(scope-operator) c-hanging-braces-alist '((brace-list-open) (brace-entry-open) (statement-cont) (substatement-open after) (block-close . c-snug-do-while) (extern-lang-open after) (namespace-open after) (module-open after) (composition-open after) (inexpr-class-open after) (inexpr-class-close before) (arglist-cont-nonempt= y)) c-hanging-colons-alist nil c-hanging-semi&comma-criteria '(c-semi&comma-inside-parenlist) c-backslash-column 48 c-backslash-max-column 72 c-special-indent-hook nil c-label-minimum-indentation 1 c-offsets-alist '((inexpr-class . +) (inexpr-statement . +) (lambda-intro-cont . +) (inlambda . 0) (template-args-cont c-lineup-template-args +) (incomposition . +) (inmodule . +) (innamespace . 0) (inextern-lang . 0) (composition-close . 0) (module-close . 0) (namespace-close . 0) (extern-lang-close . 0) (composition-open . 0) (module-open . 0) (namespace-open . 0) (extern-lang-open . 0) (objc-method-call-cont c-lineup-ObjC-method-call-colons c-lineup-ObjC-method-call + ) (objc-method-args-cont . c-lineup-ObjC-method-args) (objc-method-intro . [0]) (friend . 0) (cpp-define-intro c-lineup-cpp-define +) (cpp-macro-cont . +) (cpp-macro . [0]) (inclass . +) (stream-op . c-lineup-streamop) (arglist-cont-nonempty c-lineup-gcc-asm-reg c-lineup-arglist ) (arglist-cont c-lineup-gcc-asm-reg 0) (comment-intro c-lineup-knr-region-comment c-lineup-comment ) (catch-clause . 0) (else-clause . 0) (do-while-closure . 0) (access-label . /) (case-label . *) (substatement . +) (statement-case-intro . *) (statement . 0) (brace-entry-open . 0) (brace-list-entry . c-lineup-under-anchor) (brace-list-close . 0) (block-close . 0) (block-open . 0) (inher-cont . c-lineup-multi-inher) (inher-intro . +) (member-init-cont . c-lineup-multi-inher) (member-init-intro . +) (annotation-var-cont . +) (annotation-top-cont . 0) (topmost-intro . 0) (knr-argdecl . 0) (func-decl-cont . +) (inline-close . 0) (class-close . 0) (class-open . 0) (defun-block-intro . +) (defun-close . 0) (defun-open . 0) (c . c-lineup-C-comments) (string . c-lineup-dont-change) (topmost-intro-cont . c-lineup-topmost-intro-cont) (brace-list-intro . +) (brace-list-open . 0) (inline-open . 0) (arglist-close . +) (arglist-intro . +) (statement-cont . c-lineup-math) (statement-case-open . *) (label . *) (substatement-label . 2) (substatement-open . 0) (knr-argdecl-intro . +) (statement-block-intro . +) ) c-buffer-is-cc-mode 'c++-mode c-tab-always-indent t c-syntactic-indentation t c-syntactic-indentation-in-macros t c-ignore-auto-fill '(string cpp code) c-auto-align-backslashes t c-backspace-function 'backward-delete-char-untabify c-delete-function 'delete-char c-electric-pound-behavior nil c-default-style '((java-mode . "java") (awk-mode . "awk") (other . "gnu")) c-enable-xemacs-performance-kludge-p nil c-old-style-variable-behavior nil defun-prompt-regexp nil tab-width 8 comment-column 32 parse-sexp-ignore-comments t parse-sexp-lookup-properties t auto-fill-function nil comment-multi-line t comment-start-skip "\\(//+\\|/\\*+\\)\\s *" fill-prefix nil fill-column 70 paragraph-start "[ ]*\\(//+\\|\\**\\)[ ]*$\\|^\f" adaptive-fill-mode t adaptive-fill-regexp "[ ]*\\(//+\\|\\**\\)[ ]*\\([ ]*\\([-=E2=80=93!|#%= ;>*=C2=B7=E2=80=A2=E2=80=A3=E2=81=83=E2=97=A6]+[ ]*\\)*\\)" ) --=20 Michael Welsh Duggan (md5i@HIDDEN) --=-=-=--
Michael Welsh Duggan <mwd@HIDDEN>
:bug-cc-mode@HIDDEN
.
Full text available.bug-cc-mode@HIDDEN
:bug#32044
; Package cc-mode
.
Full text available.
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997 nCipher Corporation Ltd,
1994-97 Ian Jackson.