file
PPStrings.hPPStrings provides metaprogramming macros for operating on/with text/tokens.
MIT License
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Defines
- #define CONCAT0(...)
- Concatenates zero arguments.
- #define CONCAT1(A)
- Concatenates nothing to one argument (returns the given argument)
- #define ___CONCAT2(A, B)
- Concatenates the two arguments.
- #define CONCAT2(A, B)
- Concatenates the two arguments.
- #define CONCAT2_DEFERRED(A, B)
- Concatenates the two arguments with one additional layer of indirection.
- #define ___CONCAT3(A, B, C)
- Concatenates the three arguments.
- #define CONCAT3(A, B, C)
- Concatenates the three arguments.
- #define ___CONCAT4(A, B, C, D)
- Concatenates the four arguments.
- #define CONCAT4(A, B, C, D)
- Concatenates the four arguments.
- #define ___CONCAT5(A, B, C, D, E)
- Concatenates the five arguments.
- #define CONCAT5(A, B, C, D, E)
- Concatenates the five arguments.
- #define ___CONCAT6(A, B, C, D, E, F)
- Concatenates the 6 arguments.
- #define CONCAT6(A, B, C, D, E, F)
- Concatenates the 6 arguments.
- #define ___CONCAT7(A, B, C, D, E, F, G)
- Concatenates the 7 arguments.
- #define CONCAT7(A, B, C, D, E, F, G)
- Concatenates the 7 arguments.
- #define ___CONCAT8(A, B, C, D, E, F, G, H)
- Concatenates the 8 arguments.
- #define CONCAT8(A, B, C, D, E, F, G, H)
- Concatenates the 8 arguments.
- #define ___CONCAT9(A, B, C, D, E, F, G, H, I)
- Concatenates the 9 arguments.
- #define CONCAT9(A, B, C, D, E, F, G, H, I)
- Concatenates the 9 arguments.
- #define ___CONCAT10(A, B, C, D, E, F, G, H, I, J)
- Concatenates the 10 arguments.
- #define CONCAT10(A, B, C, D, E, F, G, H, I, J)
- Concatenates the 10 arguments.
- #define ___CONCAT11(A, B, C, D, E, F, G, H, I, J, K)
- Concatenates the 11 arguments.
- #define CONCAT11(A, B, C, D, E, F, G, H, I, J, K)
- Concatenates the 11 arguments.
- #define ___CONCAT12(A, B, C, D, E, F, G, H, I, J, K, L)
- Concatenates the 12 arguments.
- #define CONCAT12(A, B, C, D, E, F, G, H, I, J, K, L)
- Concatenates the 12 arguments.
- #define ___CONCAT13(A, B, C, D, E, F, G, H, I, J, K, L, M)
- Concatenates the 13 arguments.
- #define CONCAT13(A, B, C, D, E, F, G, H, I, J, K, L, M)
- Concatenates the 13 arguments.
- #define ___AS_STRING(x)
- Stringifies the given textual argument.
- #define AS_STRING(x)
- Stringifies the given textual argument.
Define documentation
#define ___CONCAT2(A, B)
Concatenates the two arguments.
Parameters | |
---|---|
A | - the left-side portion of the concatenation |
B | - the right-side portion of the concatenation |
Returns | the concatenation of A and B |
A
and B
must be alphanumeric, macro-concatenation compatible sequences of characters
#define ___CONCAT3(A, B, C)
Concatenates the three arguments.
Parameters | |
---|---|
A | - the left-side portion of the concatenation |
B | - the middle portion of the concatenation |
C | - the right-side portion of the concatenation |
Returns | the concatenation of A , B , and C |
A
, B
, and C
must be alphanumeric, macro-concatenation compatible sequences of characters
#define ___CONCAT4(A, B, C, D)
Concatenates the four arguments.
Parameters | |
---|---|
A | - the left-side portion of the concatenation |
B | - the left-middle portion of the concatenation |
C | - the right-middle portion of the concatenation |
D | - the right-side portion of the concatenation |
Returns | the concatenation of A , B , C , and D |
A
, B
, C
, and D
must be alphanumeric, macro-concatenation compatible sequences of characters
#define ___CONCAT5(A, B, C, D, E)
Concatenates the five arguments.
Parameters | |
---|---|
A | - the first portion of the concatenation |
B | - the second portion of the concatenation |
C | - the third portion of the concatenation |
D | - the fourth portion of the concatenation |
E | - the fifth portion of the concatenation |
Returns | the concatenation of A , B , C , D , E |
A
, B
, C
, D
, E
must be alphanumeric, macro-concatenation compatible sequences of characters
#define ___CONCAT6(A, B, C, D, E, F)
Concatenates the 6 arguments.
Parameters | |
---|---|
A | - the first portion of the concatenation |
B | - the second portion of the concatenation |
C | - the third portion of the concatenation |
D | - the fourth portion of the concatenation |
E | - the fifth portion of the concatenation |
F | - the sixth portion of the concatenation |
Returns | the concatenation of A , B , C , D , E , F |
A
, B
, C
, D
, E
, F
must be alphanumeric, macro-concatenation compatible sequences of characters
#define ___CONCAT7(A, B, C, D, E, F, G)
Concatenates the 7 arguments.
Parameters | |
---|---|
A | - the first portion of the concatenation |
B | - the second portion of the concatenation |
C | - the third portion of the concatenation |
D | - the fourth portion of the concatenation |
E | - the fifth portion of the concatenation |
F | - the sixth portion of the concatenation |
G | - the seventh portion of the concatenation |
Returns | the concatenation of A , B , C , D , E , F , G |
A
, B
, C
, D
, E
, F
, G
must be alphanumeric, macro-concatenation compatible sequences of characters
#define ___CONCAT8(A, B, C, D, E, F, G, H)
Concatenates the 8 arguments.
Parameters | |
---|---|
A | - the first portion of the concatenation |
B | - the second portion of the concatenation |
C | - the third portion of the concatenation |
D | - the fourth portion of the concatenation |
E | - the fifth portion of the concatenation |
F | - the sixth portion of the concatenation |
G | - the seventh portion of the concatenation |
H | - the eight portion of the concatenation |
Returns | the concatenation of A , B , C , D , E , F , G , H |
A
, B
, C
, D
, E
, F
, G
, H
must be alphanumeric, macro-concatenation compatible sequences of characters
#define ___CONCAT9(A, B, C, D, E, F, G, H, I)
Concatenates the 9 arguments.
Parameters | |
---|---|
A | - the first portion of the concatenation |
B | - the second portion of the concatenation |
C | - the third portion of the concatenation |
D | - the fourth portion of the concatenation |
E | - the fifth portion of the concatenation |
F | - the sixth portion of the concatenation |
G | - the seventh portion of the concatenation |
H | - the eight portion of the concatenation |
I | - the ninth portion of the concatenation |
Returns | the concatenation of A , B , C , D , E , F , G , H , I |
A
, B
, C
, D
, E
, F
, G
, H
, I
must be alphanumeric, macro-concatenation compatible sequences of characters
#define ___CONCAT10(A, B, C, D, E, F, G, H, I, J)
Concatenates the 10 arguments.
Parameters | |
---|---|
A | - the first portion of the concatenation |
B | - the second portion of the concatenation |
C | - the third portion of the concatenation |
D | - the fourth portion of the concatenation |
E | - the fifth portion of the concatenation |
F | - the sixth portion of the concatenation |
G | - the seventh portion of the concatenation |
H | - the eight portion of the concatenation |
I | - the ninth portion of the concatenation |
J | - the tenth portion of the concatenation |
Returns | the concatenation of A , B , C , D , E , F , G , H , I , J |
A
, B
, C
, D
, E
, F
, G
, H
, I
, J
must be alphanumeric, macro-concatenation compatible sequences of characters
#define ___CONCAT11(A, B, C, D, E, F, G, H, I, J, K)
Concatenates the 11 arguments.
Parameters | |
---|---|
A | - the first portion of the concatenation |
B | - the second portion of the concatenation |
C | - the third portion of the concatenation |
D | - the fourth portion of the concatenation |
E | - the fifth portion of the concatenation |
F | - the sixth portion of the concatenation |
G | - the seventh portion of the concatenation |
H | - the eight portion of the concatenation |
I | - the ninth portion of the concatenation |
J | - the tenth portion of the concatenation |
K | - the eleventh portion of the concatenation |
Returns | the concatenation of A , B , C , D , E , F , G , H , I , J , K |
A
, B
, C
, D
, E
, F
, G
, H
, I
, J
, K
must be alphanumeric, macro-concatenation compatible sequences of characters
#define ___CONCAT12(A, B, C, D, E, F, G, H, I, J, K, L)
Concatenates the 12 arguments.
Parameters | |
---|---|
A | - the first portion of the concatenation |
B | - the second portion of the concatenation |
C | - the third portion of the concatenation |
D | - the fourth portion of the concatenation |
E | - the fifth portion of the concatenation |
F | - the sixth portion of the concatenation |
G | - the seventh portion of the concatenation |
H | - the eight portion of the concatenation |
I | - the ninth portion of the concatenation |
J | - the tenth portion of the concatenation |
K | - the eleventh portion of the concatenation |
L | - the twelfth portion of the concatenation |
Returns | the concatenation of A , B , C , D , E , F , G , H , I , J , K , L |
A
, B
, C
, D
, E
, F
, G
, H
, I
, J
, K
, L
must be alphanumeric, macro-concatenation compatible sequences of characters
#define ___CONCAT13(A, B, C, D, E, F, G, H, I, J, K, L, M)
Concatenates the 13 arguments.
Parameters | |
---|---|
A | - the first portion of the concatenation |
B | - the second portion of the concatenation |
C | - the third portion of the concatenation |
D | - the fourth portion of the concatenation |
E | - the fifth portion of the concatenation |
F | - the sixth portion of the concatenation |
G | - the seventh portion of the concatenation |
H | - the eight portion of the concatenation |
I | - the ninth portion of the concatenation |
J | - the tenth portion of the concatenation |
K | - the eleventh portion of the concatenation |
L | - the twelfth portion of the concatenation |
M | - the thirteenth portion of the concatenation |
Returns | the concatenation of A , B , C , D , E , F , G , H , I , J , K , L , M |
A
, B
, C
, D
, E
, F
, G
, H
, I
, J
, K
, L
, M
must be alphanumeric, macro-concatenation compatible sequences of characters
#define ___AS_STRING(x)
Stringifies the given textual argument.
Parameters | |
---|---|
x | - The text to stringify |
Returns | x as a string literal |
Converts the given argument into a string literal, performing macro expansion if necessary