* bug#42581: Wrong C++ indentation when using class MY_DLL_EXPORT_MACRO foo @ 2020-07-28 11:34 Stephane A 2020-07-28 14:31 ` Eli Zaretskii [not found] ` <mailman.208.1595954047.2739.bug-gnu-emacs@gnu.org> 0 siblings, 2 replies; 9+ messages in thread From: Stephane A @ 2020-07-28 11:34 UTC (permalink / raw) To: 42581 [-- Attachment #1.1: Type: text/plain, Size: 501 bytes --] Hello, There is a C++ indentation problem when using: class MY_EXPORT_DLL_MACRO foo { // with a public: foo(); // This line is not indented // section. }; The problem is not reproduced if, either: - the "MY_DLL_EXPORT_MACRO" is removed; or - the "public:" section is removed Please find enclosed a sample C++ file containing the indentation problem using different C++ styles (stroustrup, linux and gnu) and the following emacs information. Best regards, Stéphane [-- Attachment #1.2: Type: text/html, Size: 1181 bytes --] [-- Attachment #2: emacs-cxx-indentation.txt --] [-- Type: text/plain, Size: 21340 bytes --] In GNU Emacs 26.1 (build 2, x86_64-pc-linux-gnu, GTK+ Version 3.24.5) of 2019-09-23, modified by Debian built on x86-grnet-01 Windowing system distributor 'The X.Org Foundation', version 11.0.12004000 System Description: Debian GNU/Linux 10 (buster) Configured using: 'configure --build x86_64-linux-gnu --prefix=/usr --sharedstatedir=/var/lib --libexecdir=/usr/lib --localstatedir=/var/lib --infodir=/usr/share/info --mandir=/usr/share/man --enable-libsystemd --with-pop=yes --enable-locallisppath=/etc/emacs:/usr/local/share/emacs/26.1/site-lisp:/usr/local/share/emacs/site-lisp:/usr/share/emacs/26.1/site-lisp:/usr/share/emacs/site-lisp --with-sound=alsa --without-gconf --with-mailutils --build x86_64-linux-gnu --prefix=/usr --sharedstatedir=/var/lib --libexecdir=/usr/lib --localstatedir=/var/lib --infodir=/usr/share/info --mandir=/usr/share/man --enable-libsystemd --with-pop=yes --enable-locallisppath=/etc/emacs:/usr/local/share/emacs/26.1/site-lisp:/usr/local/share/emacs/site-lisp:/usr/share/emacs/26.1/site-lisp:/usr/share/emacs/site-lisp --with-sound=alsa --without-gconf --with-mailutils --with-x=yes --with-x-toolkit=gtk3 --with-toolkit-scroll-bars 'CFLAGS=-g -O2 -fdebug-prefix-map=/build/emacs-StqULU/emacs-26.1+1=. -fstack-protector-strong -Wformat -Werror=format-security -Wall' 'CPPFLAGS=-Wdate-time -D_FORTIFY_SOURCE=2' LDFLAGS=-Wl,-z,relro' Configured features: XPM JPEG TIFF GIF PNG RSVG IMAGEMAGICK SOUND GPM DBUS GSETTINGS NOTIFY ACL LIBSELINUX GNUTLS LIBXML2 FREETYPE M17N_FLT LIBOTF XFT ZLIB TOOLKIT_SCROLL_BARS GTK3 X11 THREADS LIBSYSTEMD LCMS2 Important settings: value of $LANG: en_US.UTF-8 value of $XMODIFIERS: @im=ibus locale-coding-system: utf-8-unix Major mode: C++//l Minor modes in effect: gdb-many-windows: t diff-auto-refine-mode: t shell-dirtrack-mode: t show-paren-mode: t global-linum-mode: t linum-mode: t global-hl-line-mode: t tooltip-mode: t global-eldoc-mode: t electric-indent-mode: t mouse-wheel-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t size-indication-mode: t column-number-mode: t line-number-mode: t auto-fill-function: c-do-auto-fill transient-mark-mode: t abbrev-mode: t Load-path shadows: /usr/share/emacs/site-lisp/elpa/apache-mode-2.1/apache-mode hides /usr/share/emacs/site-lisp/elpa-src/apache-mode-2.1/apache-mode /usr/share/emacs/site-lisp/elpa/apache-mode-2.1/apache-mode-autoloads hides /usr/share/emacs/site-lisp/elpa-src/apache-mode-2.1/apache-mode-autoloads /usr/share/emacs/site-lisp/elpa/apache-mode-2.1/apache-mode-pkg hides /usr/share/emacs/site-lisp/elpa-src/apache-mode-2.1/apache-mode-pkg /usr/share/emacs/site-lisp/elpa/async-1.9.3/dired-async hides /usr/share/emacs/site-lisp/elpa-src/async-1.9.3/dired-async /usr/share/emacs/site-lisp/elpa/async-1.9.3/async-pkg hides /usr/share/emacs/site-lisp/elpa-src/async-1.9.3/async-pkg /usr/share/emacs/site-lisp/elpa/async-1.9.3/async-autoloads hides /usr/share/emacs/site-lisp/elpa-src/async-1.9.3/async-autoloads /usr/share/emacs/site-lisp/elpa/async-1.9.3/async hides /usr/share/emacs/site-lisp/elpa-src/async-1.9.3/async /usr/share/emacs/site-lisp/elpa/async-1.9.3/async-bytecomp hides /usr/share/emacs/site-lisp/elpa-src/async-1.9.3/async-bytecomp /usr/share/emacs/site-lisp/elpa/async-1.9.3/smtpmail-async hides /usr/share/emacs/site-lisp/elpa-src/async-1.9.3/smtpmail-async /usr/share/emacs/site-lisp/elpa/bar-cursor-2.0/bar-cursor hides /usr/share/emacs/site-lisp/elpa-src/bar-cursor-2.0/bar-cursor /usr/share/emacs/site-lisp/elpa/bar-cursor-2.0/bar-cursor-autoloads hides /usr/share/emacs/site-lisp/elpa-src/bar-cursor-2.0/bar-cursor-autoloads /usr/share/emacs/site-lisp/elpa/bar-cursor-2.0/bar-cursor-pkg hides /usr/share/emacs/site-lisp/elpa-src/bar-cursor-2.0/bar-cursor-pkg /usr/share/emacs/site-lisp/elpa/bm-201808/bm-sync hides /usr/share/emacs/site-lisp/elpa-src/bm-201808/bm-sync /usr/share/emacs/site-lisp/elpa/bm-201808/bm-autoloads hides /usr/share/emacs/site-lisp/elpa-src/bm-201808/bm-autoloads /usr/share/emacs/site-lisp/elpa/bm-201808/bm hides /usr/share/emacs/site-lisp/elpa-src/bm-201808/bm /usr/share/emacs/site-lisp/elpa/bm-201808/bm-pkg hides /usr/share/emacs/site-lisp/elpa-src/bm-201808/bm-pkg /usr/share/emacs/site-lisp/elpa/boxquote-2.1/boxquote hides /usr/share/emacs/site-lisp/elpa-src/boxquote-2.1/boxquote /usr/share/emacs/site-lisp/elpa/boxquote-2.1/boxquote-pkg hides /usr/share/emacs/site-lisp/elpa-src/boxquote-2.1/boxquote-pkg /usr/share/emacs/site-lisp/elpa/boxquote-2.1/boxquote-autoloads hides /usr/share/emacs/site-lisp/elpa-src/boxquote-2.1/boxquote-autoloads /usr/share/emacs/site-lisp/elpa/browse-kill-ring-2.0.0/browse-kill-ring-pkg hides /usr/share/emacs/site-lisp/elpa-src/browse-kill-ring-2.0.0/browse-kill-ring-pkg /usr/share/emacs/site-lisp/elpa/browse-kill-ring-2.0.0/browse-kill-ring-autoloads hides /usr/share/emacs/site-lisp/elpa-src/browse-kill-ring-2.0.0/browse-kill-ring-autoloads /usr/share/emacs/site-lisp/elpa/browse-kill-ring-2.0.0/browse-kill-ring hides /usr/share/emacs/site-lisp/elpa-src/browse-kill-ring-2.0.0/browse-kill-ring /usr/share/emacs/site-lisp/elpa/csv-mode-1.7/csv-mode-autoloads hides /usr/share/emacs/site-lisp/elpa-src/csv-mode-1.7/csv-mode-autoloads /usr/share/emacs/site-lisp/elpa/csv-mode-1.7/csv-mode hides /usr/share/emacs/site-lisp/elpa-src/csv-mode-1.7/csv-mode /usr/share/emacs/site-lisp/elpa/csv-mode-1.7/csv-mode-pkg hides /usr/share/emacs/site-lisp/elpa-src/csv-mode-1.7/csv-mode-pkg /usr/share/emacs/site-lisp/elpa/diminish-0.45/diminish hides /usr/share/emacs/site-lisp/elpa-src/diminish-0.45/diminish /usr/share/emacs/site-lisp/elpa/diminish-0.45/diminish-autoloads hides /usr/share/emacs/site-lisp/elpa-src/diminish-0.45/diminish-autoloads /usr/share/emacs/site-lisp/elpa/diminish-0.45/diminish-pkg hides /usr/share/emacs/site-lisp/elpa-src/diminish-0.45/diminish-pkg /usr/share/emacs/site-lisp/elpa/eproject-1.5/eproject-ruby-on-rails hides /usr/share/emacs/site-lisp/elpa-src/eproject-1.5/eproject-ruby-on-rails /usr/share/emacs/site-lisp/elpa/eproject-1.5/eproject-javascript-grunt hides /usr/share/emacs/site-lisp/elpa-src/eproject-1.5/eproject-javascript-grunt /usr/share/emacs/site-lisp/elpa/eproject-1.5/eproject-autoloads hides /usr/share/emacs/site-lisp/elpa-src/eproject-1.5/eproject-autoloads /usr/share/emacs/site-lisp/elpa/eproject-1.5/eproject-javascript-bower hides /usr/share/emacs/site-lisp/elpa-src/eproject-1.5/eproject-javascript-bower /usr/share/emacs/site-lisp/elpa/eproject-1.5/eproject-python hides /usr/share/emacs/site-lisp/elpa-src/eproject-1.5/eproject-python /usr/share/emacs/site-lisp/elpa/eproject-1.5/eproject-ruby hides /usr/share/emacs/site-lisp/elpa-src/eproject-1.5/eproject-ruby /usr/share/emacs/site-lisp/elpa/eproject-1.5/eproject-extras hides /usr/share/emacs/site-lisp/elpa-src/eproject-1.5/eproject-extras /usr/share/emacs/site-lisp/elpa/eproject-1.5/eproject-android hides /usr/share/emacs/site-lisp/elpa-src/eproject-1.5/eproject-android /usr/share/emacs/site-lisp/elpa/eproject-1.5/eproject-clojure-leiningen hides /usr/share/emacs/site-lisp/elpa-src/eproject-1.5/eproject-clojure-leiningen /usr/share/emacs/site-lisp/elpa/eproject-1.5/eproject-arduino hides /usr/share/emacs/site-lisp/elpa-src/eproject-1.5/eproject-arduino /usr/share/emacs/site-lisp/elpa/eproject-1.5/eproject hides /usr/share/emacs/site-lisp/elpa-src/eproject-1.5/eproject /usr/share/emacs/site-lisp/elpa/eproject-1.5/eproject-tests hides /usr/share/emacs/site-lisp/elpa-src/eproject-1.5/eproject-tests /usr/share/emacs/site-lisp/elpa/eproject-1.5/eproject-pkg hides /usr/share/emacs/site-lisp/elpa-src/eproject-1.5/eproject-pkg /usr/share/emacs/site-lisp/elpa/eproject-1.5/eproject-perl hides /usr/share/emacs/site-lisp/elpa-src/eproject-1.5/eproject-perl /usr/share/emacs/site-lisp/elpa/eproject-1.5/eproject-javascript-npm hides /usr/share/emacs/site-lisp/elpa-src/eproject-1.5/eproject-javascript-npm /usr/share/emacs/site-lisp/elpa/eproject-1.5/eproject-php-composer hides /usr/share/emacs/site-lisp/elpa-src/eproject-1.5/eproject-php-composer /usr/share/emacs/site-lisp/elpa/folding-20170925.1538/folding-pkg hides /usr/share/emacs/site-lisp/elpa-src/folding-20170925.1538/folding-pkg /usr/share/emacs/site-lisp/elpa/folding-20170925.1538/folding hides /usr/share/emacs/site-lisp/elpa-src/folding-20170925.1538/folding /usr/share/emacs/site-lisp/elpa/folding-20170925.1538/folding-autoloads hides /usr/share/emacs/site-lisp/elpa-src/folding-20170925.1538/folding-autoloads /usr/share/emacs/site-lisp/elpa/graphviz-dot-mode-0.3.10/graphviz-dot-mode hides /usr/share/emacs/site-lisp/elpa-src/graphviz-dot-mode-0.3.10/graphviz-dot-mode /usr/share/emacs/site-lisp/elpa/graphviz-dot-mode-0.3.10/graphviz-dot-mode-autoloads hides /usr/share/emacs/site-lisp/elpa-src/graphviz-dot-mode-0.3.10/graphviz-dot-mode-autoloads /usr/share/emacs/site-lisp/elpa/graphviz-dot-mode-0.3.10/graphviz-dot-mode-pkg hides /usr/share/emacs/site-lisp/elpa-src/graphviz-dot-mode-0.3.10/graphviz-dot-mode-pkg /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-utils hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-utils /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-help hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-help /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-man hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-man /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-config hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-config /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-net hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-net /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-color hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-color /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-dabbrev hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-dabbrev /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-regexp hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-regexp /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-x-files hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-x-files /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-eval hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-eval /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-adaptive hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-adaptive /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-for-files hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-for-files /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-grep hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-grep /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-types hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-types /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-elisp hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-elisp /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-elisp-package hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-elisp-package /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-misc hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-misc /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-easymenu hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-easymenu /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-imenu hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-imenu /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-autoloads hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-autoloads /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-pkg hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-pkg /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-id-utils hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-id-utils /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-info hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-info /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-eshell hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-eshell /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-find hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-find /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-semantic hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-semantic /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-mode hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-mode /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-org hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-org /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-font hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-font /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-ring hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-ring /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-tags hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-tags /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-files hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-files /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-external hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-external /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-buffers hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-buffers /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-bookmark hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-bookmark /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-locate hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-locate /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-command hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-command /usr/share/emacs/site-lisp/elpa/helm-3.0/helm-sys hides /usr/share/emacs/site-lisp/elpa-src/helm-3.0/helm-sys /usr/share/emacs/site-lisp/elpa/helm-core-3.0/helm hides /usr/share/emacs/site-lisp/elpa-src/helm-core-3.0/helm /usr/share/emacs/site-lisp/elpa/helm-core-3.0/helm-multi-match hides /usr/share/emacs/site-lisp/elpa-src/helm-core-3.0/helm-multi-match /usr/share/emacs/site-lisp/elpa/helm-core-3.0/helm-source hides /usr/share/emacs/site-lisp/elpa-src/helm-core-3.0/helm-source /usr/share/emacs/site-lisp/elpa/helm-core-3.0/helm-core-pkg hides /usr/share/emacs/site-lisp/elpa-src/helm-core-3.0/helm-core-pkg /usr/share/emacs/site-lisp/elpa/helm-core-3.0/helm-core-autoloads hides /usr/share/emacs/site-lisp/elpa-src/helm-core-3.0/helm-core-autoloads /usr/share/emacs/site-lisp/elpa/helm-core-3.0/helm-lib hides /usr/share/emacs/site-lisp/elpa-src/helm-core-3.0/helm-lib /usr/share/emacs/site-lisp/elpa/htmlize-1.54/htmlize hides /usr/share/emacs/site-lisp/elpa-src/htmlize-1.54/htmlize /usr/share/emacs/site-lisp/elpa/htmlize-1.54/htmlize-autoloads hides /usr/share/emacs/site-lisp/elpa-src/htmlize-1.54/htmlize-autoloads /usr/share/emacs/site-lisp/elpa/htmlize-1.54/htmlize-pkg hides /usr/share/emacs/site-lisp/elpa-src/htmlize-1.54/htmlize-pkg /usr/share/emacs/site-lisp/elpa/initsplit-1.8/initsplit hides /usr/share/emacs/site-lisp/elpa-src/initsplit-1.8/initsplit /usr/share/emacs/site-lisp/elpa/initsplit-1.8/initsplit-pkg hides /usr/share/emacs/site-lisp/elpa-src/initsplit-1.8/initsplit-pkg /usr/share/emacs/site-lisp/elpa/initsplit-1.8/initsplit-test hides /usr/share/emacs/site-lisp/elpa-src/initsplit-1.8/initsplit-test /usr/share/emacs/site-lisp/elpa/initsplit-1.8/initsplit-autoloads hides /usr/share/emacs/site-lisp/elpa-src/initsplit-1.8/initsplit-autoloads /usr/share/emacs/site-lisp/elpa/markdown-mode-2.3snapshot154/markdown-mode-autoloads hides /usr/share/emacs/site-lisp/elpa-src/markdown-mode-2.3snapshot154/markdown-mode-autoloads /usr/share/emacs/site-lisp/elpa/markdown-mode-2.3snapshot154/markdown-mode-pkg hides /usr/share/emacs/site-lisp/elpa-src/markdown-mode-2.3snapshot154/markdown-mode-pkg /usr/share/emacs/site-lisp/elpa/markdown-mode-2.3snapshot154/markdown-mode hides /usr/share/emacs/site-lisp/elpa-src/markdown-mode-2.3snapshot154/markdown-mode /usr/share/emacs/site-lisp/elpa/mutt-alias-1.4/mutt-alias-autoloads hides /usr/share/emacs/site-lisp/elpa-src/mutt-alias-1.4/mutt-alias-autoloads /usr/share/emacs/site-lisp/elpa/mutt-alias-1.4/mutt-alias hides /usr/share/emacs/site-lisp/elpa-src/mutt-alias-1.4/mutt-alias /usr/share/emacs/site-lisp/elpa/mutt-alias-1.4/mutt-alias-pkg hides /usr/share/emacs/site-lisp/elpa-src/mutt-alias-1.4/mutt-alias-pkg /usr/share/emacs/site-lisp/elpa/muttrc-mode-1.2.1/muttrc-mode-pkg hides /usr/share/emacs/site-lisp/elpa-src/muttrc-mode-1.2.1/muttrc-mode-pkg /usr/share/emacs/site-lisp/elpa/muttrc-mode-1.2.1/muttrc-mode-autoloads hides /usr/share/emacs/site-lisp/elpa-src/muttrc-mode-1.2.1/muttrc-mode-autoloads /usr/share/emacs/site-lisp/elpa/muttrc-mode-1.2.1/muttrc-mode hides /usr/share/emacs/site-lisp/elpa-src/muttrc-mode-1.2.1/muttrc-mode /usr/share/emacs/site-lisp/elpa/pod-mode-1.3/pod-mode hides /usr/share/emacs/site-lisp/elpa-src/pod-mode-1.3/pod-mode /usr/share/emacs/site-lisp/elpa/pod-mode-1.3/pod-mode-autoloads hides /usr/share/emacs/site-lisp/elpa-src/pod-mode-1.3/pod-mode-autoloads /usr/share/emacs/site-lisp/elpa/pod-mode-1.3/pod-mode-pkg hides /usr/share/emacs/site-lisp/elpa-src/pod-mode-1.3/pod-mode-pkg /usr/share/emacs/site-lisp/elpa/popup-0.5.3/popup hides /usr/share/emacs/site-lisp/elpa-src/popup-0.5.3/popup /usr/share/emacs/site-lisp/elpa/popup-0.5.3/popup-autoloads hides /usr/share/emacs/site-lisp/elpa-src/popup-0.5.3/popup-autoloads /usr/share/emacs/site-lisp/elpa/popup-0.5.3/popup-pkg hides /usr/share/emacs/site-lisp/elpa-src/popup-0.5.3/popup-pkg /usr/share/emacs/site-lisp/elpa/session-2.4.2/session hides /usr/share/emacs/site-lisp/elpa-src/session-2.4.2/session /usr/share/emacs/site-lisp/elpa/session-2.4.2/session-autoloads hides /usr/share/emacs/site-lisp/elpa-src/session-2.4.2/session-autoloads /usr/share/emacs/site-lisp/elpa/session-2.4.2/session-pkg hides /usr/share/emacs/site-lisp/elpa-src/session-2.4.2/session-pkg /usr/share/emacs/site-lisp/elpa/tabbar-20160524/aquamacs-tabbar hides /usr/share/emacs/site-lisp/elpa-src/tabbar-20160524/aquamacs-tabbar /usr/share/emacs/site-lisp/elpa/tabbar-20160524/tabbar-pkg hides /usr/share/emacs/site-lisp/elpa-src/tabbar-20160524/tabbar-pkg /usr/share/emacs/site-lisp/elpa/tabbar-20160524/tabbar-window hides /usr/share/emacs/site-lisp/elpa-src/tabbar-20160524/tabbar-window /usr/share/emacs/site-lisp/elpa/tabbar-20160524/aquamacs-compat hides /usr/share/emacs/site-lisp/elpa-src/tabbar-20160524/aquamacs-compat /usr/share/emacs/site-lisp/elpa/tabbar-20160524/tabbar hides /usr/share/emacs/site-lisp/elpa-src/tabbar-20160524/tabbar /usr/share/emacs/site-lisp/elpa/tabbar-20160524/tabbar-autoloads hides /usr/share/emacs/site-lisp/elpa-src/tabbar-20160524/tabbar-autoloads /usr/share/emacs/site-lisp/elpa/tabbar-20160524/aquamacs-tools hides /usr/share/emacs/site-lisp/elpa-src/tabbar-20160524/aquamacs-tools /usr/share/emacs/site-lisp/elpa/tabbar-20160524/one-buffer-one-frame hides /usr/share/emacs/site-lisp/elpa-src/tabbar-20160524/one-buffer-one-frame /usr/share/emacs/site-lisp/elpa/yaml-mode-0.0.13/yaml-mode-pkg hides /usr/share/emacs/site-lisp/elpa-src/yaml-mode-0.0.13/yaml-mode-pkg /usr/share/emacs/site-lisp/elpa/yaml-mode-0.0.13/yaml-mode-autoloads hides /usr/share/emacs/site-lisp/elpa-src/yaml-mode-0.0.13/yaml-mode-autoloads /usr/share/emacs/site-lisp/elpa/yaml-mode-0.0.13/yaml-mode hides /usr/share/emacs/site-lisp/elpa-src/yaml-mode-0.0.13/yaml-mode Features: (goto-addr noutline outline view help-mode pp shadow sort mail-extr emacsbug message rmc puny format-spec rfc822 mml mml-sec epa epg gnus-util rmail rmail-loaddefs mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils browse-url vc vc-dispatcher gdb-mi bindat json map gud grep dired dired-loaddefs misearch multi-isearch gtags imenu cc-mode cc-fonts cc-guess cc-menus cc-cmds compile make-mode vc-git diff-mode easy-mmode cmake-mode thingatpt derived rx shell pcomplete comint ansi-color ring elec-pair finder-inf info cc-styles cc-align cc-engine cc-vars cc-defs paren linum hl-line cus-start cus-load package easymenu epg-config url-handlers url-parse auth-source cl-seq eieio eieio-core cl-macs eieio-loaddefs password-cache url-vars seq byte-opt gv bytecomp byte-compile cconv cl-loaddefs cl-lib time-date mule-util tooltip eldoc electric uniquify ediff-hook vc-hooks lisp-float-type mwheel term/x-win x-win term/common-win x-dnd tool-bar dnd fontset image regexp-opt fringe tabulated-list replace newcomment text-mode elisp-mode lisp-mode prog-mode register page menu-bar rfn-eshadow isearch timer select scroll-bar mouse jit-lock font-lock syntax facemenu font-core term/tty-colors frame cl-generic cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese composite charscript charprop case-table epa-hook jka-cmpr-hook help simple abbrev obarray minibuffer cl-preloaded nadvice loaddefs button faces cus-face macroexp files text-properties overlay sha1 md5 base64 format env code-pages mule custom widget hashtable-print-readable backquote dbusbind inotify lcms2 dynamic-setting system-font-setting font-render-setting move-toolbar gtk x-toolkit x multi-tty make-network-process emacs) Memory information: ((conses 16 408484 31579) (symbols 48 34795 3) (miscs 40 5263 937) (strings 32 102372 5384) (string-bytes 1 2744122) (vectors 16 30554) (vector-slots 8 747495 22064) (floats 8 116 461) (intervals 56 13958 1813) (buffers 992 55)) [-- Attachment #3: emacs-cxx-indentation.cpp --] [-- Type: text/x-c++src, Size: 1210 bytes --] // Stroustup style. class stroustrup_1 { stroustrup_1(); }; class stroustrup_2 { public: stroustrup_2(); }; class MY_DLL_EXPORT stroustrup_3 { stroustrup_3(); }; class MY_DLL_EXPORT stroustrup_4 { public: stroustrup_4(); // Wrong indentation because of the presence of MY_DLL_EXPORT. }; class MY_DLL_EXPORT stroustrup_5 { public: stroustrup_4(); // Wrong indentation because of the presence of MY_DLL_EXPORT. }; // linux style class linux_1 { linux_1(); }; class linux_2 { public: linux_2(); }; class MY_DLL_EXPORT linux_3 { linux_3(); }; class MY_DLL_EXPORT linux_4 { public: linux_4(); // Wrong indentation because of the presence of MY_DLL_EXPORT. }; class MY_DLL_EXPORT linux_5 { public: linux_5(); // Wrong indentation because of the presence of MY_DLL_EXPORT. }; // gnu style. class gnu_1 { gnu_1(); }; class gnu_2 { public: gnu_2(); }; class MY_DLL_EXPORT gnu_3 { gnu_3(); }; class MY_DLL_EXPORT gnu_4 { public: gnu_4(); // Wrong indentation because of the presence of MY_DLL_EXPORT. }; class MY_DLL_EXPORT gnu_5 { public: gnu_5(); // Wrong indentation because of the presence of MY_DLL_EXPORT. }; ^ permalink raw reply [flat|nested] 9+ messages in thread
* bug#42581: Wrong C++ indentation when using class MY_DLL_EXPORT_MACRO foo 2020-07-28 11:34 bug#42581: Wrong C++ indentation when using class MY_DLL_EXPORT_MACRO foo Stephane A @ 2020-07-28 14:31 ` Eli Zaretskii 2020-07-28 16:06 ` Stephane A [not found] ` <mailman.208.1595954047.2739.bug-gnu-emacs@gnu.org> 1 sibling, 1 reply; 9+ messages in thread From: Eli Zaretskii @ 2020-07-28 14:31 UTC (permalink / raw) To: Stephane A; +Cc: 42581 > From: Stephane A <a.stephane.fsw@gmail.com> > Date: Tue, 28 Jul 2020 13:34:43 +0200 > > There is a C++ indentation problem when using: > class MY_EXPORT_DLL_MACRO foo { > // with a > public: > foo(); // This line is not indented > // section. > }; > > The problem is not reproduced if, either: > > * the "MY_DLL_EXPORT_MACRO" is removed; or > * the "public:" section is removed Does it help to add MY_DLL_EXPORT_MACRO to the list in c-noise-macro-names? ^ permalink raw reply [flat|nested] 9+ messages in thread
* bug#42581: Wrong C++ indentation when using class MY_DLL_EXPORT_MACRO foo 2020-07-28 14:31 ` Eli Zaretskii @ 2020-07-28 16:06 ` Stephane A 0 siblings, 0 replies; 9+ messages in thread From: Stephane A @ 2020-07-28 16:06 UTC (permalink / raw) To: Eli Zaretskii; +Cc: 42581 [-- Attachment #1: Type: text/plain, Size: 1174 bytes --] Hello, Thank you for the advice :) I didn't know this one. We have on *_EXPORT macro per module. So I would need to configure noise macros by regexp. I found *c-make-noise-macro-regexps *in the Emacs documentation <https://www.gnu.org/software/emacs/manual/html_node/ccmode/Noise-Macros.html> but don't know how to set it up in my emacs file <https://github.com/astephane/emacs/blob/master/emacs.el> since the syntax is not documented. I though of adding a call to the c++-mode-hook <https://github.com/astephane/emacs/blob/master/emacs.el#L245>. Regards, Stéphane On Tue, Jul 28, 2020 at 4:31 PM Eli Zaretskii <eliz@gnu.org> wrote: > > From: Stephane A <a.stephane.fsw@gmail.com> > > Date: Tue, 28 Jul 2020 13:34:43 +0200 > > > > There is a C++ indentation problem when using: > > class MY_EXPORT_DLL_MACRO foo { > > // with a > > public: > > foo(); // This line is not indented > > // section. > > }; > > > > The problem is not reproduced if, either: > > > > * the "MY_DLL_EXPORT_MACRO" is removed; or > > * the "public:" section is removed > > Does it help to add MY_DLL_EXPORT_MACRO to the list in > c-noise-macro-names? > [-- Attachment #2: Type: text/html, Size: 1832 bytes --] ^ permalink raw reply [flat|nested] 9+ messages in thread
[parent not found: <mailman.208.1595954047.2739.bug-gnu-emacs@gnu.org>]
* bug#42581: Wrong C++ indentation when using class MY_DLL_EXPORT_MACRO foo [not found] ` <mailman.208.1595954047.2739.bug-gnu-emacs@gnu.org> @ 2020-07-28 18:38 ` Alan Mackenzie [not found] ` <CA+Q2SshAeQD_gN+dC3U8FEdf1xVB2GTpObK=vjC6fn-Ox=_w6A@mail.gmail.com> 0 siblings, 1 reply; 9+ messages in thread From: Alan Mackenzie @ 2020-07-28 18:38 UTC (permalink / raw) To: Stephane A; +Cc: 42581, acm In article <mailman.208.1595954047.2739.bug-gnu-emacs@gnu.org> you wrote: > [-- text/plain, encoding quoted-printable, charset: UTF-8, 41 lines --] > Hello, > Thank you for the advice :) I didn't know this one. > We have on *_EXPORT macro per module. So I would need to configure noise > macros by regexp. > I found *c-make-noise-macro-regexps *in the Emacs documentation > <https://www.gnu.org/software/emacs/manual/html_node/ccmode/Noise-Macros.html> > but don't know how to set it up in my emacs file > <https://github.com/astephane/emacs/blob/master/emacs.el> since the syntax > is not documented. The syntax and semantics or regular expressions are documented thoroughly in the Emacs Lisp manual (elisp.info). The mechanics of the CC Mode hooks are similarly described in the CC Mode manual (ccmode.info). c-noise-macro-names can be either a list of strings (one of which would be "MY_EXPORT_DLL_MACRO") or just a regular expression, which you seem to need here. There is an example .emacs file in an appendix to the CC Mode manual. > I though of adding a call to the c++-mode-hook > <https://github.com/astephane/emacs/blob/master/emacs.el#L245>. The c++-mode-hook would be an excellent place to make this setting, yes. > Regards, > Stéphane > On Tue, Jul 28, 2020 at 4:31 PM Eli Zaretskii <eliz@gnu.org> wrote: >> > From: Stephane A <a.stephane.fsw@gmail.com> >> > Date: Tue, 28 Jul 2020 13:34:43 +0200 >> > >> > There is a C++ indentation problem when using: >> > class MY_EXPORT_DLL_MACRO foo { >> > // with a >> > public: >> > foo(); // This line is not indented >> > // section. >> > }; >> > >> > The problem is not reproduced if, either: >> > >> > * the "MY_DLL_EXPORT_MACRO" is removed; or >> > * the "public:" section is removed >> >> Does it help to add MY_DLL_EXPORT_MACRO to the list in >> c-noise-macro-names? >> -- Alan Mackenzie (Nuremberg, Germany). ^ permalink raw reply [flat|nested] 9+ messages in thread
[parent not found: <CA+Q2SshAeQD_gN+dC3U8FEdf1xVB2GTpObK=vjC6fn-Ox=_w6A@mail.gmail.com>]
* bug#42581: Wrong C++ indentation when using class MY_DLL_EXPORT_MACRO foo [not found] ` <CA+Q2SshAeQD_gN+dC3U8FEdf1xVB2GTpObK=vjC6fn-Ox=_w6A@mail.gmail.com> @ 2020-07-31 19:44 ` Alan Mackenzie 2020-08-03 9:30 ` Stephane A 0 siblings, 1 reply; 9+ messages in thread From: Alan Mackenzie @ 2020-07-31 19:44 UTC (permalink / raw) To: Stephane A; +Cc: 42581, acm Hello, Stéphane. Just one little thing: could you please keep the buglist address in the Cc: when you reply, so that everybody can keep track of the conversation. Thanks. On Wed, Jul 29, 2020 at 10:28:07 +0200, Stephane A wrote: > On Tue, Jul 28, 2020 at 8:38 PM Alan Mackenzie <acm@muc.de> wrote: > > In article <mailman.208.1595954047.2739.bug-gnu-emacs@gnu.org> you wrote: > > > [-- text/plain, encoding quoted-printable, charset: UTF-8, 41 lines --] > > > Hello, > > > Thank you for the advice :) I didn't know this one. > > > We have on *_EXPORT macro per module. So I would need to configure noise > > > macros by regexp. > > > I found *c-make-noise-macro-regexps *in the Emacs documentation > > > < > > https://www.gnu.org/software/emacs/manual/html_node/ccmode/Noise-Macros.html > > > but don't know how to set it up in my emacs file > > > <https://github.com/astephane/emacs/blob/master/emacs.el> since the > > syntax > > > is not documented. > > The syntax and semantics or regular expressions are documented > > thoroughly in the Emacs Lisp manual (elisp.info). > > The mechanics of the CC Mode hooks are similarly described in the CC > > Mode manual (ccmode.info). c-noise-macro-names can be either a list of > > strings (one of which would be "MY_EXPORT_DLL_MACRO") or just a regular > > expression, which you seem to need here. > > There is an example .emacs file in an appendix to the CC Mode manual. > > > I though of adding a call to the c++-mode-hook > > > <https://github.com/astephane/emacs/blob/master/emacs.el#L245>. > > The c++-mode-hook would be an excellent place to make this setting, yes. > Following the CC mode example [1], I added (add-to-list 'c-noise-macro-names > "[:space:].+_EXPORT[:space:]") in the lambda of the c++-mode-hook [2], but > there's no difference of indentation in the code (I check with > linux/gnu/stroustrup styles). I don't know if I've done something wrong or > if this workaround does work. There are a couple of misunderstandings, here (for which I blame the documentation (largely written by me)). Firstly, the regexp must match the noise macro exactly, not also any spaces which may be around it, or anything like that. So your regexp should look something like: "[A-Z_]+_MACRO" ; which matches "MY_EXPORT_DLL_MACRO" or "MODULE_[A-Z_]_+EXPORT" ; which matches "MODULES_NAME_EXPORT". > Note: our macros are of the form MODULE_NAME_EXPORT. Also, your `add-to-list' form is mistaken. That would give you a one element list, that element being the regexp. What you need is the variable set to the regexp itself. For this, you want something like: (setq c-noise-macro-names "MODULE_[A-Z_]+_EXPORT") > [1] > https://www.gnu.org/software/emacs/manual/html_node/ccmode/Sample-Init-File.html#Sample-Init-File > [2] https://github.com/astephane/emacs/blob/master/emacs.el#L254 > Regards, > Stéphane -- Alan Mackenzie (Nuremberg, Germany). ^ permalink raw reply [flat|nested] 9+ messages in thread
* bug#42581: Wrong C++ indentation when using class MY_DLL_EXPORT_MACRO foo 2020-07-31 19:44 ` Alan Mackenzie @ 2020-08-03 9:30 ` Stephane A 2020-08-14 8:01 ` Stephane A 0 siblings, 1 reply; 9+ messages in thread From: Stephane A @ 2020-08-03 9:30 UTC (permalink / raw) To: Alan Mackenzie; +Cc: 42581 [-- Attachment #1: Type: text/plain, Size: 3763 bytes --] Hello Alan, Thank you very much for your help. I succeeded in configuring my CC-mode successfully :) One more question: How would I do to set a list of macros ignored using c-noise-macro-names ? Sorry, for the bug report. This is my first time. Regarding the bug, I noticed that if there's a class derivation, the indentation world correctly, e.g.: class MY_EXPORT foo : public bar { public: foo(); // Indentation OK here if ': public bar', NOK otherwise. }; Regards, Stéphane On Fri, Jul 31, 2020 at 9:44 PM Alan Mackenzie <acm@muc.de> wrote: > Hello, Stéphane. > > Just one little thing: could you please keep the buglist address in the > Cc: when you reply, so that everybody can keep track of the conversation. > Thanks. > > On Wed, Jul 29, 2020 at 10:28:07 +0200, Stephane A wrote: > > On Tue, Jul 28, 2020 at 8:38 PM Alan Mackenzie <acm@muc.de> wrote: > > > > In article <mailman.208.1595954047.2739.bug-gnu-emacs@gnu.org> you > wrote: > > > > [-- text/plain, encoding quoted-printable, charset: UTF-8, 41 lines > --] > > > > > Hello, > > > > > Thank you for the advice :) I didn't know this one. > > > > > We have on *_EXPORT macro per module. So I would need to configure > noise > > > > macros by regexp. > > > > > I found *c-make-noise-macro-regexps *in the Emacs documentation > > > > < > > > > https://www.gnu.org/software/emacs/manual/html_node/ccmode/Noise-Macros.html > > > > > but don't know how to set it up in my emacs file > > > > <https://github.com/astephane/emacs/blob/master/emacs.el> since the > > > syntax > > > > is not documented. > > > > The syntax and semantics or regular expressions are documented > > > thoroughly in the Emacs Lisp manual (elisp.info). > > > > The mechanics of the CC Mode hooks are similarly described in the CC > > > Mode manual (ccmode.info). c-noise-macro-names can be either a list > of > > > strings (one of which would be "MY_EXPORT_DLL_MACRO") or just a regular > > > expression, which you seem to need here. > > > > There is an example .emacs file in an appendix to the CC Mode manual. > > > > > I though of adding a call to the c++-mode-hook > > > > <https://github.com/astephane/emacs/blob/master/emacs.el#L245>. > > > > The c++-mode-hook would be an excellent place to make this setting, > yes. > > > > Following the CC mode example [1], I added (add-to-list > 'c-noise-macro-names > > "[:space:].+_EXPORT[:space:]") in the lambda of the c++-mode-hook [2], > but > > there's no difference of indentation in the code (I check with > > linux/gnu/stroustrup styles). I don't know if I've done something wrong > or > > if this workaround does work. > > There are a couple of misunderstandings, here (for which I blame the > documentation (largely written by me)). > > Firstly, the regexp must match the noise macro exactly, not also any > spaces which may be around it, or anything like that. So your regexp > should look something like: > > "[A-Z_]+_MACRO" ; which matches "MY_EXPORT_DLL_MACRO" > or > "MODULE_[A-Z_]_+EXPORT" ; which matches "MODULES_NAME_EXPORT". > > > Note: our macros are of the form MODULE_NAME_EXPORT. > > Also, your `add-to-list' form is mistaken. That would give you a one > element list, that element being the regexp. What you need is the > variable set to the regexp itself. For this, you want something like: > > (setq c-noise-macro-names "MODULE_[A-Z_]+_EXPORT") > > > [1] > > > https://www.gnu.org/software/emacs/manual/html_node/ccmode/Sample-Init-File.html#Sample-Init-File > > [2] https://github.com/astephane/emacs/blob/master/emacs.el#L254 > > > > Regards, > > > Stéphane > > -- > Alan Mackenzie (Nuremberg, Germany). > [-- Attachment #2: Type: text/html, Size: 5914 bytes --] ^ permalink raw reply [flat|nested] 9+ messages in thread
* bug#42581: Wrong C++ indentation when using class MY_DLL_EXPORT_MACRO foo 2020-08-03 9:30 ` Stephane A @ 2020-08-14 8:01 ` Stephane A 2021-12-05 1:03 ` Lars Ingebrigtsen 0 siblings, 1 reply; 9+ messages in thread From: Stephane A @ 2020-08-14 8:01 UTC (permalink / raw) To: Alan Mackenzie; +Cc: 42581 [-- Attachment #1: Type: text/plain, Size: 4230 bytes --] Hello, The noise macro works for indentation, but it seems to cause the syntax highlight to not be done correctly when opening a file. I must edit the file to force refresh so that grammatical elements are detected. Regards, Stéphane On Mon, Aug 3, 2020 at 11:30 AM Stephane A <a.stephane.fsw@gmail.com> wrote: > Hello Alan, > > Thank you very much for your help. I succeeded in configuring my CC-mode > successfully :) > > One more question: How would I do to set a list of macros ignored using > c-noise-macro-names ? > > Sorry, for the bug report. This is my first time. > > Regarding the bug, I noticed that if there's a class derivation, the > indentation world correctly, e.g.: > class MY_EXPORT foo : public bar { > public: > foo(); // Indentation OK here if ': public bar', NOK otherwise. > }; > > Regards, > > Stéphane > > On Fri, Jul 31, 2020 at 9:44 PM Alan Mackenzie <acm@muc.de> wrote: > >> Hello, Stéphane. >> >> Just one little thing: could you please keep the buglist address in the >> Cc: when you reply, so that everybody can keep track of the conversation. >> Thanks. >> >> On Wed, Jul 29, 2020 at 10:28:07 +0200, Stephane A wrote: >> > On Tue, Jul 28, 2020 at 8:38 PM Alan Mackenzie <acm@muc.de> wrote: >> >> > > In article <mailman.208.1595954047.2739.bug-gnu-emacs@gnu.org> you >> wrote: >> > > > [-- text/plain, encoding quoted-printable, charset: UTF-8, 41 lines >> --] >> >> > > > Hello, >> >> > > > Thank you for the advice :) I didn't know this one. >> >> > > > We have on *_EXPORT macro per module. So I would need to configure >> noise >> > > > macros by regexp. >> >> > > > I found *c-make-noise-macro-regexps *in the Emacs documentation >> > > > < >> > > >> https://www.gnu.org/software/emacs/manual/html_node/ccmode/Noise-Macros.html >> >> > > > but don't know how to set it up in my emacs file >> > > > <https://github.com/astephane/emacs/blob/master/emacs.el> since the >> > > syntax >> > > > is not documented. >> >> > > The syntax and semantics or regular expressions are documented >> > > thoroughly in the Emacs Lisp manual (elisp.info). >> >> > > The mechanics of the CC Mode hooks are similarly described in the CC >> > > Mode manual (ccmode.info). c-noise-macro-names can be either a list >> of >> > > strings (one of which would be "MY_EXPORT_DLL_MACRO") or just a >> regular >> > > expression, which you seem to need here. >> >> > > There is an example .emacs file in an appendix to the CC Mode manual. >> >> > > > I though of adding a call to the c++-mode-hook >> > > > <https://github.com/astephane/emacs/blob/master/emacs.el#L245>. >> >> > > The c++-mode-hook would be an excellent place to make this setting, >> yes. >> >> >> > Following the CC mode example [1], I added (add-to-list >> 'c-noise-macro-names >> > "[:space:].+_EXPORT[:space:]") in the lambda of the c++-mode-hook [2], >> but >> > there's no difference of indentation in the code (I check with >> > linux/gnu/stroustrup styles). I don't know if I've done something wrong >> or >> > if this workaround does work. >> >> There are a couple of misunderstandings, here (for which I blame the >> documentation (largely written by me)). >> >> Firstly, the regexp must match the noise macro exactly, not also any >> spaces which may be around it, or anything like that. So your regexp >> should look something like: >> >> "[A-Z_]+_MACRO" ; which matches "MY_EXPORT_DLL_MACRO" >> or >> "MODULE_[A-Z_]_+EXPORT" ; which matches "MODULES_NAME_EXPORT". >> >> > Note: our macros are of the form MODULE_NAME_EXPORT. >> >> Also, your `add-to-list' form is mistaken. That would give you a one >> element list, that element being the regexp. What you need is the >> variable set to the regexp itself. For this, you want something like: >> >> (setq c-noise-macro-names "MODULE_[A-Z_]+_EXPORT") >> >> > [1] >> > >> https://www.gnu.org/software/emacs/manual/html_node/ccmode/Sample-Init-File.html#Sample-Init-File >> > [2] https://github.com/astephane/emacs/blob/master/emacs.el#L254 >> >> >> > Regards, >> >> > Stéphane >> >> -- >> Alan Mackenzie (Nuremberg, Germany). >> > [-- Attachment #2: Type: text/html, Size: 6622 bytes --] ^ permalink raw reply [flat|nested] 9+ messages in thread
* bug#42581: Wrong C++ indentation when using class MY_DLL_EXPORT_MACRO foo 2020-08-14 8:01 ` Stephane A @ 2021-12-05 1:03 ` Lars Ingebrigtsen 2022-01-21 13:38 ` Lars Ingebrigtsen 0 siblings, 1 reply; 9+ messages in thread From: Lars Ingebrigtsen @ 2021-12-05 1:03 UTC (permalink / raw) To: Stephane A; +Cc: Alan Mackenzie, 42581 Stephane A <a.stephane.fsw@gmail.com> writes: > The noise macro works for indentation, but it seems to cause the > syntax highlight to not be done correctly when opening a file. I must > edit the file to force refresh so that grammatical elements are > detected. (I'm going through old bug reports that unfortunately weren't resolved at the time.) Skimming this bug report, it's not entirely clear to me what the actual problem here is. If it's still a problem, could you post a recipe to reproduce the problem, starting from "emacs -Q"? -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no ^ permalink raw reply [flat|nested] 9+ messages in thread
* bug#42581: Wrong C++ indentation when using class MY_DLL_EXPORT_MACRO foo 2021-12-05 1:03 ` Lars Ingebrigtsen @ 2022-01-21 13:38 ` Lars Ingebrigtsen 0 siblings, 0 replies; 9+ messages in thread From: Lars Ingebrigtsen @ 2022-01-21 13:38 UTC (permalink / raw) To: Stephane A; +Cc: Alan Mackenzie, 42581 Lars Ingebrigtsen <larsi@gnus.org> writes: > Skimming this bug report, it's not entirely clear to me what the actual > problem here is. If it's still a problem, could you post a recipe to > reproduce the problem, starting from "emacs -Q"? More information was requested, but no response was given within a month, so I'm closing this bug report. If the problem still exists, please respond to this email and we'll reopen the bug report. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no ^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2022-01-21 13:38 UTC | newest] Thread overview: 9+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2020-07-28 11:34 bug#42581: Wrong C++ indentation when using class MY_DLL_EXPORT_MACRO foo Stephane A 2020-07-28 14:31 ` Eli Zaretskii 2020-07-28 16:06 ` Stephane A [not found] ` <mailman.208.1595954047.2739.bug-gnu-emacs@gnu.org> 2020-07-28 18:38 ` Alan Mackenzie [not found] ` <CA+Q2SshAeQD_gN+dC3U8FEdf1xVB2GTpObK=vjC6fn-Ox=_w6A@mail.gmail.com> 2020-07-31 19:44 ` Alan Mackenzie 2020-08-03 9:30 ` Stephane A 2020-08-14 8:01 ` Stephane A 2021-12-05 1:03 ` Lars Ingebrigtsen 2022-01-21 13:38 ` Lars Ingebrigtsen
Code repositories for project(s) associated with this public inbox https://git.savannah.gnu.org/cgit/emacs.git This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).