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?

stdio.hやiostream.hの中身を見る方法

Posted at

a.cppにて

#include <stdio.h>

b.cppにて

#include <iostream>

を作成し、このファイルを以下のオプションを付けた状態でコンパイルする

g++ -E -P a.cpp > stdio_h.txt
g++ -E -P b.cpp > iostream.txt

これを行うことによりstdio_h.txtとiostream.txtの中にそれぞれコンパイルする際に本来ならプリコンパイルされるヘッダ内のテキストが.txtに出力された状態で生成できる

ちなみに、
-E ・・・プリプロセス結果を出力(#line付き)
-P ・・・#lineを消した状態にする
のオプションになります

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?