Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
BBSMenu: Fix compiler warning for -Wdefaulted-function-deleted (#1309)
親クラス Loadable のmove constructorは暗黙的に削除されているため 子クラス BBSMenu のmove constructorに対してclangが警告を出しました。 BBSMenu のコピーやムーブは今のところ行っていないため move constructorをdeleteに変更して修正します。 clang-16のレポート ``` In file included from ../src/bbslist/bbslistview.cpp:11: ../src/dbtree/bbsmenu.h:63:5: error: explicitly defaulted move constructor is implicitly deleted [-Werror,-Wdefaulted-function-deleted] BBSMenu( BBSMenu&& ) noexcept(kSupportNoexceptDefaultCtor)= default; ^ ../src/dbtree/bbsmenu.h:35:17: note: move constructor of 'BBSMenu' is implicitly deleted because base class 'SKELETON::Loadable' has a deleted move constructor class BBSMenu : public SKELETON::Loadable ^ ../src/skeleton/loadable.h:71:40: note: copy constructor of 'Loadable' is implicitly deleted because field 'm_loader' has a deleted copy constructor std::unique_ptr<JDLIB::Loader> m_loader; ^ /usr/bin/../lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/bits/unique_ptr.h:522:7: note: 'unique_ptr' has been explicitly marked deleted here unique_ptr(const unique_ptr&) = delete; ^ ../src/dbtree/bbsmenu.h:63:65: note: replace 'default' with 'delete' BBSMenu( BBSMenu&& ) noexcept(kSupportNoexceptDefaultCtor)= default; ^~~~~~~ delete ../src/dbtree/bbsmenu.h:68:14: error: explicitly defaulted move assignment operator is implicitly deleted [-Werror,-Wdefaulted-function-deleted] BBSMenu& operator=( BBSMenu&& ) noexcept(kSupportNoexceptDefaultCtor) = default; ^ ```
- Loading branch information