GNU bug report logs - #32041
CC Mode 5.33.1 (C++//l); noexcept confuses member-init handling

Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.

Package: cc-mode; Reported by: Michael Welsh Duggan <mwd@HIDDEN>; dated Mon, 2 Jul 2018 20:04:02 UTC; Maintainer for cc-mode is bug-cc-mode@HIDDEN.

Message received at submit <at> debbugs.gnu.org:


Received: (at submit) by debbugs.gnu.org; 2 Jul 2018 20:03:29 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Mon Jul 02 16:03:29 2018
Received: from localhost ([127.0.0.1]:43942 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1fa52m-0006WP-Vi
	for submit <at> debbugs.gnu.org; Mon, 02 Jul 2018 16:03:29 -0400
Received: from md5i.com ([75.151.244.229]:44268)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <mwd@HIDDEN>) id 1fa52l-0006WH-0K
 for submit <at> debbugs.gnu.org; Mon, 02 Jul 2018 16:03:27 -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=JUSeCG6zoejM8A7PGLc4ct1Y4AnPu1lQ9sJ6KjlruB0=; b=Vx12JfK+SzUg2VWXo2gVFmOX+N
 qQMfDQPUjygu4VozQXHl1Ks1N/yCSquFsMg18W7ZZOx9Q0pi+rc4s3MnNq4scqeR/L4Xe3pzD2OOc
 J06m9VQpGDK1Wz1NL+ArXyIlg;
Received: from md5i by md5i.com with local (Exim 4.91)
 (envelope-from <mwd@HIDDEN>) id 1fa52k-0006pu-Gf
 for submit <at> debbugs.gnu.org; Mon, 02 Jul 2018 16:03:26 -0400
From: Michael Welsh Duggan <mwd@HIDDEN>
To: submit <at> debbugs.gnu.org
Subject: CC Mode 5.33.1 (C++//l); noexcept confuses member-init handling
X-Debbugs-Package: cc-mode
Date: Mon, 02 Jul 2018 16:03:01 -0400
Message-ID: <87r2kl2yoa.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

In the included test the member initialization for Foo() is indented
correctly, whereas the ones for Bar() and Baz() are not.


--=-=-=
Content-Type: text/x-c\+\+
Content-Disposition: inline

struct Foo
{
  int x;
  Foo()
    : x(0)                      // member-init-intro (correct)
  {}
};

struct Bar
{
  int x;
  Bar() noexcept
  : x(0)                        // topmost-intro-cont (incorrect)
  {}
};

struct Baz
{
  int x;
  Baz() noexcept(true)
  : x(0)                        // topmost-intro-cont (incorrect)
  {}
};

--=-=-=
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)

--=-=-=--




Acknowledgement sent to Michael Welsh Duggan <mwd@HIDDEN>:
New bug report received and forwarded. Copy sent to bug-cc-mode@HIDDEN. Full text available.
Report forwarded to bug-cc-mode@HIDDEN:
bug#32041; Package cc-mode. Full text available.
Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.
Last modified: Mon, 25 Nov 2019 12:00:02 UTC

GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997 nCipher Corporation Ltd, 1994-97 Ian Jackson.