Andes Workshop
https://forum.andestech.com/

What does "##" mean in a macro? (Concatenation)
https://forum.andestech.com/viewtopic.php?f=25&t=935
Page 1 of 1

Author:  ianfeng [ Mon Sep 14, 2015 3:16 pm ]
Post subject:  What does "##" mean in a macro? (Concatenation)

We may see "##" in Andes demo project, such as below line.
Code:
#define HW_ISR(n)               HW##n##_ISR

What does it mean?

The ‘##’ preprocessing operator performs token pasting.

For detail information, please refer following website.
https://gcc.gnu.org/onlinedocs/cpp/Concatenation.html

Page 1 of 1 All times are UTC + 8 hours [ DST ]
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/