some question about macro define

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

some question about macro define

615件の閲覧回数
100asong
Contributor I

1.For example,"#define Days 365 " macro definition sentence can been defined in code area and ram area?

2.There are some difference about these 2 area?

ラベル(1)
0 件の賞賛
1 返信

300件の閲覧回数
CrasyCat
Specialist III

Hello

 

I am not sure I understand the question here.

 

The statement ,"#define Days 365" is basically a macro definition.

The pre-processor will basically replace all occurrence of Days by 365 at the very beginning of the build process.

 

As such a macro does not occupy any space in either ROM or RAM.

 

CrasyCat

0 件の賞賛