はじめに(Introduction)
N4910 Working Draft, Standard for Programming Language C++
n4910は、ISO/IEC JTC1 SC22 WG21の作業原案(Working Draft)です。
公式のISO/IEC 14882原本ではありません。
ISO/IEC JTC1 SC22 WG21では、可能な限り作業文書を公開し、幅広い意見を求めています。
一連の記事はコード断片をコンパイルできる形にする方法を検討してコンパイル、リンク、実行して、規格案の原文と処理系(g++, Clang++)との違いを確認し、技術内容を検討し、ISO/IEC JTC1 SC22 WG21にフィードバックするために用います。
また、CERT C++, MISRA C++等のコーディング標準のコード断片をコンパイルする際の参考にさせていただこうと考えています。CERT C++, MISRA C++が標準化の動きとの時間的なずれがあれば確認できれば幸いです。また、boostライブラリとの関連、Linux OS, TOPPERSカーネル、g++(GCC), clang++(LLVM)との関係も調査中です。
何か、抜け漏れ、耳より情報がありましたらおしらせくださると幸いです。
<この項は書きかけです。順次追記します。>
背景(back ground)
C/C++でコンパイルエラーが出ると、途方にくれることがしばしばあります。
何回かに1回は、該当するエラーが検索できます。
ただ、条件が違っていて、そこでの修正方法では目的を達成しないこともしばしばです。いろいろな条件のコンパイルエラーとその対応方法について、広く記録することによって、いつか同じエラーに遭遇した時にやくに立つことを目指しています。
この半年の間で、三度、自分のネットでの記録に助けられたことがあります。
また過去に解決できなかった記録を10種類以上、最近になって解決できたことがあります。それは、主に次の3つの情報に基づいています。
cpprefjp - C++日本語リファレンス
コンパイラの実装状況
また
https://researchmap.jp/joub9b3my-1797580/#_1797580
に記載したサイトのお世話になっています。
作業方針(sequence)
Clang++では-std=c++03, C++2bの2種類
g++では-std=c++03, c++2bの2種類
でコンパイルし、
1)コンパイルエラーを収集する。
2)コンパイルエラーをなくす方法を検討する。
コンパイルエラーになる例を示すだけが目的のコードは、コンパイルエラーをなくすのではなく、コンパイルエラーの種類を収集するだけにする。
文法を示すのが目的のコード場合に、コンパイルエラーをなくすのに手間がかかる場合は、順次作業します。
3)リンクエラーをなくす方法を検討する。
文法を示すのが目的のコード場合に、リンクエラーをなくすのに手間がかかる場合は、順次作業します。
4)意味のある出力を作る。
コンパイル、リンクが通っても、意味のある出力を示そうとすると、コンパイル・リンクエラーが出て収拾できそうにない場合がある。順次作業します。
1)だけのものから4)まで進んだものと色々ある状態です。一歩でも前に進むご助言をお待ちしています。「検討事項」の欄に現状を記録するようにしています。
C++N4910:2022 Standard Working Draft on ISO/IEC 14882(0) sample code compile list
C++N4741, 2018 Standard Working Draft on ISO/IEC 14882 sample code compile list
C++N4606, 2016符号断片編纂一覧(example code compile list)
C++N4606, 2016 Working Draft 2016, ISO/IEC 14882, C++ standard(1) Example code compile list
https://qiita.com/kaizen_nagoya/items/df5d62c35bd6ed1c3d43/
C++N3242, 2011 sample code compile list on clang++ and g++
編纂器(Compiler)
clang++ --version
Debian clang version 14.0.5-++20220610033153+c12386ae247c-1~exp1~20220610153237.151
Target: x86_64-pc-linux-gnu, Thread model: posix, InstalledDir: /usr/bin
g++- --version
g++ (GCC) 12.1.0 Copyright (C) 2022 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
27.5 Algorithm result types [algorithms.results] C++N4910:2022 (659) p1190.cpp
算譜(source code)
// C++N4910 Committee Draft, Standard for Programming Language C++
// http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2022/n4910.pdf
const char * n4910 = "27.5 Algorithm result types [algorithms.results] C++N4910:2022 (659) p1190.cpp";
// Debian clang version 14.0.5-++20220610033153+c12386ae247c-
// g++ (GCC) 12.1.0 Copyright (C) 2022 Free Software Foundation, Inc.
// Edited by Dr. OGAWA Kiyoshi. Compile procedure and results record.
// C++N4910:2022 Standard Working Draft on ISO/IEC 14882(0) sample code compile list
// https://qiita.com/kaizen_nagoya/items/fc957ddddd402004bb91
#include "N4910.h"
using namespace std;
// 27.5 Algorithm result types [algorithms.results]
// Each of the class templates specified in this subclause has the template parameters, data members, and special members specified below, and has no base classes or members other than those specified.
namespace std::ranges {
template<class I, class F>
struct in_fun_result {
[[no_unique_address]] I in;
[[no_unique_address]] F fun;
template<class I2, class F2>
requires convertible_to<const I&, I2> && convertible_to<const F&, F2>
constexpr operator in_fun_result<I2, F2>() const & {
return {in, fun};
}
template<class I2, class F2>
requires convertible_to<I, I2> && convertible_to<F, F2>
constexpr operator in_fun_result<I2, F2>() && {
return {std::move(in), std::move(fun)};
}
};
template<class I1, class I2>
struct in_in_result {
[[no_unique_address]] I1 in1;
[[no_unique_address]] I2 in2;
template<class II1, class II2>
requires convertible_to<const I1&, II1> && convertible_to<const I2&, II2>
constexpr operator in_in_result<II1, II2>() const & {
return {in1, in2};
}
template<class II1, class II2>
requires convertible_to<I1, II1> && convertible_to<I2, II2>
constexpr operator in_in_result<II1, II2>() && {
return {std::move(in1), std::move(in2)};
}
};
template<class I, class O>
struct in_out_result {
[[no_unique_address]] I in;
[[no_unique_address]] O out;
template<class I2, class O2>
requires convertible_to<const I&, I2> && convertible_to<const O&, O2>
constexpr operator in_out_result<I2, O2>() const & {
return {in, out};
}
template<class I2, class O2>
requires convertible_to<I, I2> && convertible_to<O, O2>
constexpr operator in_out_result<I2, O2>() && {
return {std::move(in), std::move(out)};
}
};
template<class I1, class I2, class O>
struct in_in_out_result {
[[no_unique_address]] I1 in1;
[[no_unique_address]] I2 in2;
[[no_unique_address]] O out;
template<class II1, class II2, class OO>
requires convertible_to<const I1&, II1> &&
convertible_to<const I2&, II2> &&
convertible_to<const O&, OO>
constexpr operator in_in_out_result<II1, II2, OO>() const & {
return {in1, in2, out};
}
template<class II1, class II2, class OO>
requires convertible_to<I1, II1> &&
convertible_to<I2, II2> &&
convertible_to<O, OO>
constexpr operator in_in_out_result<II1, II2, OO>() && {
return {std::move(in1), std::move(in2), std::move(out)};
}
};
template<class I, class O1, class O2>
struct in_out_out_result {
[[no_unique_address]] I in;
[[no_unique_address]] O1 out1;
[[no_unique_address]] O2 out2;
template<class II, class OO1, class OO2>
requires convertible_to<const I&, II> &&
convertible_to<const O1&, OO1> &&
convertible_to<const O2&, OO2>
constexpr operator in_out_out_result<II, OO1, OO2>() const & {
return {in, out1, out2};
}
template<class II, class OO1, class OO2>
requires convertible_to<I, II> &&
convertible_to<O1, OO1> &&
convertible_to<O2, OO2>
constexpr operator in_out_out_result<II, OO1, OO2>() && {
return {std::move(in), std::move(out1), std::move(out2)};
}
};
template<class T>
struct min_max_result {
[[no_unique_address]] T min;
[[no_unique_address]] T max;
template<class T2>
requires convertible_to<const T&, T2>
constexpr operator min_max_result<T2>() const & {
return {min, max};
}
template<class T2>
requires convertible_to<T, T2>
constexpr operator min_max_result<T2>() && {
return {std::move(min), std::move(max)};
}
};
template<class I>
struct in_found_result {
[[no_unique_address]] I in;
bool found;
template<class I2>
requires convertible_to<const I&, I2>
constexpr operator in_found_result<I2>() const & {
return {in, found};
}
template<class I2>
requires convertible_to<I, I2>
constexpr operator in_found_result<I2>() && {
return {std::move(in), found};
indirect_unary_predicate<projected<iterator_t<R>, Proj>> Pred>
constexpr bool ranges::all_of(R&& r, Pred pred, Proj proj = {});
// Let E be: - pred(*i) for the overloads in namespace std;
// - invoke(pred, invoke(proj, *i)) for the overloads in namespace ranges.
// Returns: false if E is false for some iterator i in the range [first, last), and true otherwise.
// Complexity: At most last - first applications of the predicate and any projection.
indirect_unary_predicate<projected<iterator_t<R>, Proj>> Pred>
constexpr bool ranges::any_of(R&& r, Pred pred, Proj proj = {});
// Let E be: - pred(*i) for the overloads in namespace std;
// - invoke(pred, invoke(proj, *i)) for the overloads in namespace ranges.
}
};
template<class O, class T>
struct out_value_result {
[[no_unique_address]] O out;
[[no_unique_address]] T value;
template<class O2, class T2>
requires convertible_to<const O&, O2> && convertible_to<const T&, T2>
constexpr operator out_value_result<O2, T2>() const & {
return {out, value};
}
template<class O2, class T2>
requires convertible_to<O, O2> && convertible_to<T, T2>
constexpr operator out_value_result<O2, T2>() && {
return {std::move(out), std::move(value)};
}
};
}
int main() {
cout << n4910 << endl;
return EXIT_SUCCESS;
}
編纂・実行結果(compile and go)
$ clang++ p1190.cpp -std=03 -o p1190l -I. -Wall
In file included from p1190.cpp:10:
In file included from ./N4910.h:11:
In file included from /usr/bin/../lib/gcc/x86_64-linux-gnu/10/../../../../include/c++/10/atomic:38:
/usr/bin/../lib/gcc/x86_64-linux-gnu/10/../../../../include/c++/10/bits/c++0x_warning.h:32:2: error: This file requires compiler and library support for the ISO C++ 2011 standard. This support must be enabled with the -std=c++11 or -std=gnu++11 compiler options.
#error This file requires compiler and library support \
^
p1190.cpp:16:19: warning: nested namespace definition is a C++17 extension; define each namespace separately [-Wc++17-extensions]
namespace std::ranges {
^~~~~~~~
{ namespace ranges
p1190.cpp:19:11: error: expected expression
[[no_unique_address]] I in;
^
p1190.cpp:19:32: error: C++ requires a type specifier for all declarations
[[no_unique_address]] I in;
^
p1190.cpp:19:32: error: declaration of 'I' shadows template parameter
p1190.cpp:17:23: note: template parameter is declared here
template<class I, class F>
^
p1190.cpp:19:33: error: expected ';' at end of declaration list
[[no_unique_address]] I in;
^
;
p1190.cpp:20:11: error: expected expression
[[no_unique_address]] F fun;
^
p1190.cpp:20:32: error: C++ requires a type specifier for all declarations
[[no_unique_address]] F fun;
^
p1190.cpp:20:32: error: declaration of 'F' shadows template parameter
p1190.cpp:17:32: note: template parameter is declared here
template<class I, class F>
^
p1190.cpp:20:33: error: expected ';' at end of declaration list
[[no_unique_address]] F fun;
^
;
p1190.cpp:22:5: error: unknown type name 'requires'
requires convertible_to<const I&, I2> && convertible_to<const F&, F2>
^
p1190.cpp:22:35: error: unknown type name 'I'
requires convertible_to<const I&, I2> && convertible_to<const F&, F2>
^
p1190.cpp:33:4: error: expected expression
[[no_unique_address]] I1 in1;
^
p1190.cpp:33:25: error: C++ requires a type specifier for all declarations
[[no_unique_address]] I1 in1;
^
p1190.cpp:33:25: error: declaration of 'I1' shadows template parameter
p1190.cpp:31:16: note: template parameter is declared here
template<class I1, class I2>
^
p1190.cpp:33:27: error: expected ';' at end of declaration list
[[no_unique_address]] I1 in1;
^
;
p1190.cpp:34:4: error: expected expression
[[no_unique_address]] I2 in2;
^
p1190.cpp:34:25: error: C++ requires a type specifier for all declarations
[[no_unique_address]] I2 in2;
^
p1190.cpp:34:25: error: declaration of 'I2' shadows template parameter
p1190.cpp:31:26: note: template parameter is declared here
template<class I1, class I2>
^
p1190.cpp:34:27: error: expected ';' at end of declaration list
[[no_unique_address]] I2 in2;
^
;
fatal error: too many errors emitted, stopping now [-ferror-limit=]
1 warning and 20 errors generated.
$ clang++ p1190.cpp -std=2b -o p1190l -I. -Wall
p1190.cpp:46:8: error: redefinition of 'in_out_result'
struct in_out_result {
^
/usr/bin/../lib/gcc/x86_64-linux-gnu/10/../../../../include/c++/10/bits/ranges_algobase.h:162:12: note: previous definition is here
struct in_out_result
^
p1190.cpp:126:54: error: use of undeclared identifier 'R'
indirect_unary_predicate<projected<iterator_t<R>, Proj>> Pred>
^
p1190.cpp:126:8: error: expected 'auto' or 'decltype(auto)' after concept name
indirect_unary_predicate<projected<iterator_t<R>, Proj>> Pred>
^
auto
p1190.cpp:126:65: error: declaration of variable 'Pred' with deduced type 'auto' requires an initializer
indirect_unary_predicate<projected<iterator_t<R>, Proj>> Pred>
^
p1190.cpp:126:69: error: expected ';' at end of declaration
indirect_unary_predicate<projected<iterator_t<R>, Proj>> Pred>
^
;
p1190.cpp:132:54: error: use of undeclared identifier 'R'
indirect_unary_predicate<projected<iterator_t<R>, Proj>> Pred>
^
p1190.cpp:132:8: error: expected 'auto' or 'decltype(auto)' after concept name
indirect_unary_predicate<projected<iterator_t<R>, Proj>> Pred>
^
auto
p1190.cpp:132:65: error: declaration of variable 'Pred' with deduced type 'auto' requires an initializer
indirect_unary_predicate<projected<iterator_t<R>, Proj>> Pred>
^
p1190.cpp:132:69: error: expected ';' at end of declaration
indirect_unary_predicate<projected<iterator_t<R>, Proj>> Pred>
^
;
9 errors generated.
$ g++ p1190.cpp -std=03 -o p1190g -I. -Wall
In file included from /usr/local/include/c++/12.1.0/atomic:38,
from N4910.h:11,
from p1190.cpp:10:
/usr/local/include/c++/12.1.0/bits/c++0x_warning.h:32:2: error: #error This file requires compiler and library support for the ISO C++ 2011 standard. This support must be enabled with the -std=c++11 or -std=gnu++11 compiler options.
32 | #error This file requires compiler and library support \
| ^~~~~
p1190.cpp:23:3: warning: identifier 'constexpr' is a keyword in C++11 [-Wc++11-compat]
23 | constexpr operator in_fun_result<I2, F2>() const & {
| ^~~~~~~~~
p1190.cpp:19:10: error: expected unqualified-id before '[' token
19 | [[no_unique_address]] I in;
| ^
p1190.cpp:20:10: error: expected unqualified-id before '[' token
20 | [[no_unique_address]] F fun;
| ^
p1190.cpp:22:5: error: 'requires' does not name a type
22 | requires convertible_to<const I&, I2> && convertible_to<const F&, F2>
| ^~~~~~~~
p1190.cpp:22:5: note: 'requires' only available with '-std=c++20' or '-fconcepts'
p1190.cpp:27:5: error: 'requires' does not name a type
27 | requires convertible_to<I, I2> && convertible_to<F, F2>
| ^~~~~~~~
p1190.cpp:27:5: note: 'requires' only available with '-std=c++20' or '-fconcepts'
p1190.cpp:33:3: error: expected unqualified-id before '[' token
33 | [[no_unique_address]] I1 in1;
| ^
p1190.cpp:34:3: error: expected unqualified-id before '[' token
34 | [[no_unique_address]] I2 in2;
| ^
p1190.cpp:36:5: error: 'requires' does not name a type
36 | requires convertible_to<const I1&, II1> && convertible_to<const I2&, II2>
| ^~~~~~~~
p1190.cpp:36:5: note: 'requires' only available with '-std=c++20' or '-fconcepts'
p1190.cpp:41:5: error: 'requires' does not name a type
41 | requires convertible_to<I1, II1> && convertible_to<I2, II2>
| ^~~~~~~~
p1190.cpp:41:5: note: 'requires' only available with '-std=c++20' or '-fconcepts'
p1190.cpp:47:3: error: expected unqualified-id before '[' token
47 | [[no_unique_address]] I in;
| ^
p1190.cpp:48:3: error: expected unqualified-id before '[' token
48 | [[no_unique_address]] O out;
| ^
p1190.cpp:50:5: error: 'requires' does not name a type
50 | requires convertible_to<const I&, I2> && convertible_to<const O&, O2>
| ^~~~~~~~
p1190.cpp:50:5: note: 'requires' only available with '-std=c++20' or '-fconcepts'
p1190.cpp:55:5: error: 'requires' does not name a type
55 | requires convertible_to<I, I2> && convertible_to<O, O2>
| ^~~~~~~~
p1190.cpp:55:5: note: 'requires' only available with '-std=c++20' or '-fconcepts'
p1190.cpp:61:3: error: expected unqualified-id before '[' token
61 | [[no_unique_address]] I1 in1;
| ^
p1190.cpp:62:3: error: expected unqualified-id before '[' token
62 | [[no_unique_address]] I2 in2;
| ^
p1190.cpp:63:3: error: expected unqualified-id before '[' token
63 | [[no_unique_address]] O out;
| ^
p1190.cpp:65:5: error: 'requires' does not name a type
65 | requires convertible_to<const I1&, II1> &&
| ^~~~~~~~
p1190.cpp:65:5: note: 'requires' only available with '-std=c++20' or '-fconcepts'
p1190.cpp:72:5: error: 'requires' does not name a type
72 | requires convertible_to<I1, II1> &&
| ^~~~~~~~
p1190.cpp:72:5: note: 'requires' only available with '-std=c++20' or '-fconcepts'
p1190.cpp:81:3: error: expected unqualified-id before '[' token
81 | [[no_unique_address]] I in;
| ^
p1190.cpp:82:3: error: expected unqualified-id before '[' token
82 | [[no_unique_address]] O1 out1;
| ^
p1190.cpp:83:3: error: expected unqualified-id before '[' token
83 | [[no_unique_address]] O2 out2;
| ^
p1190.cpp:85:5: error: 'requires' does not name a type
85 | requires convertible_to<const I&, II> &&
| ^~~~~~~~
p1190.cpp:85:5: note: 'requires' only available with '-std=c++20' or '-fconcepts'
p1190.cpp:92:5: error: 'requires' does not name a type
92 | requires convertible_to<I, II> &&
| ^~~~~~~~
p1190.cpp:92:5: note: 'requires' only available with '-std=c++20' or '-fconcepts'
p1190.cpp:101:3: error: expected unqualified-id before '[' token
101 | [[no_unique_address]] T min;
| ^
p1190.cpp:102:3: error: expected unqualified-id before '[' token
102 | [[no_unique_address]] T max;
| ^
p1190.cpp:104:5: error: 'requires' does not name a type
104 | requires convertible_to<const T&, T2>
| ^~~~~~~~
p1190.cpp:104:5: note: 'requires' only available with '-std=c++20' or '-fconcepts'
p1190.cpp:109:5: error: 'requires' does not name a type
109 | requires convertible_to<T, T2>
| ^~~~~~~~
p1190.cpp:109:5: note: 'requires' only available with '-std=c++20' or '-fconcepts'
p1190.cpp:115:3: error: expected unqualified-id before '[' token
115 | [[no_unique_address]] I in;
| ^
p1190.cpp:118:5: error: 'requires' does not name a type
118 | requires convertible_to<const I&, I2>
| ^~~~~~~~
p1190.cpp:118:5: note: 'requires' only available with '-std=c++20' or '-fconcepts'
p1190.cpp:123:5: error: 'requires' does not name a type
123 | requires convertible_to<I, I2>
| ^~~~~~~~
p1190.cpp:123:5: note: 'requires' only available with '-std=c++20' or '-fconcepts'
p1190.cpp:139:5: error: expected unqualified-id before '[' token
139 | [[no_unique_address]] O out;
| ^
p1190.cpp:140:5: error: expected unqualified-id before '[' token
140 | [[no_unique_address]] T value;
| ^
p1190.cpp:142:7: error: 'requires' does not name a type
142 | requires convertible_to<const O&, O2> && convertible_to<const T&, T2>
| ^~~~~~~~
p1190.cpp:142:7: note: 'requires' only available with '-std=c++20' or '-fconcepts'
p1190.cpp:147:7: error: 'requires' does not name a type
147 | requires convertible_to<O, O2> && convertible_to<T, T2>
| ^~~~~~~~
p1190.cpp:147:7: note: 'requires' only available with '-std=c++20' or '-fconcepts'
$ g++ p1190.cpp -std=2b -o p1190g -I. -Wall
p1190.cpp:46:8: error: redefinition of 'struct std::ranges::in_out_result<_Iter, _Out>'
46 | struct in_out_result {
| ^~~~~~~~~~~~~
In file included from /usr/local/include/c++/12.1.0/bits/ranges_uninitialized.h:36,
from /usr/local/include/c++/12.1.0/memory:86,
from N4910.h:14,
from p1190.cpp:10:
/usr/local/include/c++/12.1.0/bits/ranges_algobase.h:162:12: note: previous definition of 'struct std::ranges::in_out_result<_Iter, _Out>'
162 | struct in_out_result
| ^~~~~~~~~~~~~
p1190.cpp: In member function 'constexpr std::ranges::in_found_result<I>::operator std::ranges::in_found_result<I2>() &&':
p1190.cpp:126:54: error: 'R' was not declared in this scope
126 | indirect_unary_predicate<projected<iterator_t<R>, Proj>> Pred>
| ^
p1190.cpp:126:55: error: template argument 1 is invalid
126 | indirect_unary_predicate<projected<iterator_t<R>, Proj>> Pred>
| ^
p1190.cpp:126:58: error: 'Proj' was not declared in this scope; did you mean 'proj'?
126 | indirect_unary_predicate<projected<iterator_t<R>, Proj>> Pred>
| ^~~~
| proj
p1190.cpp:126:58: error: template argument 1 is invalid
p1190.cpp:126:58: error: template argument 2 is invalid
p1190.cpp:126:8: error: wrong number of template arguments (1, should be 2)
126 | indirect_unary_predicate<projected<iterator_t<R>, Proj>> Pred>
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/local/include/c++/12.1.0/bits/stl_iterator_base_types.h:71,
from /usr/local/include/c++/12.1.0/bits/stl_construct.h:61,
from /usr/local/include/c++/12.1.0/bits/char_traits.h:46,
from /usr/local/include/c++/12.1.0/ios:40,
from /usr/local/include/c++/12.1.0/ostream:38,
from /usr/local/include/c++/12.1.0/iostream:39,
from N4910.h:2:
/usr/local/include/c++/12.1.0/bits/iterator_concepts.h:710:13: note: provided for 'template<class _Fn, class _Iter> concept std::indirect_unary_predicate'
710 | concept indirect_unary_predicate = indirectly_readable<_Iter>
| ^~~~~~~~~~~~~~~~~~~~~~~~
p1190.cpp:127:63: error: expected primary-expression before ')' token
127 | constexpr bool ranges::all_of(R&& r, Pred pred, Proj proj = {});
| ^
p1190.cpp:132:58: error: template argument 1 is invalid
132 | indirect_unary_predicate<projected<iterator_t<R>, Proj>> Pred>
| ^~~~
p1190.cpp:132:8: error: wrong number of template arguments (1, should be 2)
132 | indirect_unary_predicate<projected<iterator_t<R>, Proj>> Pred>
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/local/include/c++/12.1.0/bits/iterator_concepts.h:710:13: note: provided for 'template<class _Fn, class _Iter> concept std::indirect_unary_predicate'
710 | concept indirect_unary_predicate = indirectly_readable<_Iter>
| ^~~~~~~~~~~~~~~~~~~~~~~~
p1190.cpp:133:63: error: expected primary-expression before ')' token
133 | constexpr bool ranges::any_of(R&& r, Pred pred, Proj proj = {});
| ^
検討事項(agenda)
コンパイルエラーを取るか、コンパイルエラーの理由を解説する。
参考資料(reference)
関連する自己参照以外は、こちらの先頭に移転。
C言語(C++)に対する誤解、曲解、無理解、爽快。
#include "N4910.h"
C++N4910資料の改善点
dockerにclang
docker gnu(gcc/g++) and llvm(clang/clang++)
コンパイル用shell script C版(clangとgcc)とC++版(clang++とg++)
C++N4910:2022 tag follower 300人超えました。ありがとうございます。
astyle 使ってみた
DoCAP(ドゥーキャップ)って何ですか?
小川メソッド 覚え(書きかけ)
<この記事は個人の過去の経験に基づく個人の感想です。現在所属する組織、業務とは関係がありません。>
文書履歴(document history)
ver. 0.01 初稿 20220814