0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

C++N4910コンパイル実験で、
ソースコードの部品のコンパイル試験を実施していて、
PDFから持って来る時に開業が抜けて、コメントの後ろについたままのことがある。

C++で一番困るのが、template。

よく考えたら、grepすればわかるじゃん。

bash
# grep template p706.cpp
template<class T, class... Args> constexpr T& emplace(Args&&... args);
template<class T, class U, class... Args>
// where I is the zero-based index of T in Types. template<size_t I, class... Args>
template<size_t I, class U, class... Args>

コメント行にtemplateの文字列があったら、説明文か実行分かを判定すればよい。

特に、今回の作業では、実行可能な説明文はコンパイルするようにしている。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?