Skip to content

Instantly share code, notes, and snippets.

@liuyix
Created May 7, 2013 02:08
Show Gist options
  • Select an option

  • Save liuyix/5529798 to your computer and use it in GitHub Desktop.

Select an option

Save liuyix/5529798 to your computer and use it in GitHub Desktop.
C/C++ Macro string concatenation

If they're both strings you can just do:

#define STR3 STR1 STR2

The preprocessor automatically concatenates adjacent strings.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment