build failure with Fedora 40 (gcc 14.1.1)

オープン
#1,966 コメント 1 件 リアクション 2 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
35/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
停滞
技術スタック
cpp
領域
build-system

調査の方向性

Start with include/ola/base/Macro.h and the DISALLOW_COPY_AND_ASSIGN uses in include/ola/thread/FuturePrivate.h. Reproduce the configure and build command on Fedora 40 with GCC 14.1.1, then update the affected declarations so the build no longer emits template-id-cdtor errors. Done means the project builds successfully with warnings treated as errors.

索引モデルが issue の本文から書いたものです。

説明

bug Language-C++ Maintainability

I'm packaging this for Fedora 40 and I hit the following build error:

In file included from ./include/ola/Clock.h:32:
./include/ola/base/Macro.h:45:11: error: template-id not allowed for constructor in C++20 [-Werror=template-id-cdtor]
   45 |   TypeName(const TypeName&);               \
      |           ^
./include/ola/thread/FuturePrivate.h:92:3: note: in expansion of macro 'DISALLOW_COPY_AND_ASSIGN'
   92 |   DISALLOW_COPY_AND_ASSIGN(FutureImpl<T>);
      |   ^~~~~~~~~~~~~~~~~~~~~~~~
./include/ola/base/Macro.h:45:11: note: remove the '< >'
   45 |   TypeName(const TypeName&);               \
      |           ^
./include/ola/thread/FuturePrivate.h:92:3: note: in expansion of macro 'DISALLOW_COPY_AND_ASSIGN'
   92 |   DISALLOW_COPY_AND_ASSIGN(FutureImpl<T>);
      |   ^~~~~~~~~~~~~~~~~~~~~~~~
./include/ola/base/Macro.h:45:11: error: template-id not allowed for constructor in C++20 [-Werror=template-id-cdtor]
   45 |   TypeName(const TypeName&);               \
      |           ^
./include/ola/thread/FuturePrivate.h:155:3: note: in expansion of macro 'DISALLOW_COPY_AND_ASSIGN'
  155 |   DISALLOW_COPY_AND_ASSIGN(FutureImpl<void>);
      |   ^~~~~~~~~~~~~~~~~~~~~~~~
./include/ola/base/Macro.h:45:11: note: remove the '< >'
   45 |   TypeName(const TypeName&);               \
      |           ^
./include/ola/thread/FuturePrivate.h:155:3: note: in expansion of macro 'DISALLOW_COPY_AND_ASSIGN'
  155 |   DISALLOW_COPY_AND_ASSIGN(FutureImpl<void>);
      |   ^~~~~~~~~~~~~~~~~~~~~~~~
cc1plus: all warnings being treated as errors
make[2]: *** [Makefile:11568: common/thread/libolacommon_la-ExecutorThread.lo] Error 1

Compiler was gcc-c++-14.1.1-7.fc40, configure line was:

+ ./configure --build=x86_64-redhat-linux --host=x86_64-redhat-linux --program-prefix= --disable-dependency-tracking --prefix=/usr --exec-prefix=/usr --bindir=/usr/bin --sbindir=/usr/sbin --sysconfdir=/etc --datadir=/usr/share --includedir=/usr/include --libdir=/usr/lib64 --libexecdir=/usr/libexec --localstatedir=/var --runstatedir=/run --sharedstatedir=/var/lib --mandir=/usr/share/man --infodir=/usr/share/info --disable-static --enable-python-libs --enable-tcmalloc

See https://clang.llvm.org/extra/clang-tidy/checks/modernize/replace-disallow-copy-and-assign-macro.html for a modern replacement for this macro.

主要言語
C++
スター
771
フォーク
234
PR マージ指標
30日以内にマージされた PR はありません

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

OpenLightingProject/ola のほかの issue

OpenLightingProject/ola の issue をすべて見る

似ている issue

C++ の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。