It is possible using some macroes and tags to specifically match a "sub-pattern", here's an example:
https://github.com/pBlueG/SA-MP-MySQL/bl...#L185-L189
The thing with tags is that it allows you to define more than one macro replacement for a function (it is technically recognized as different because of the tags). This example macro will match a literal string and variables tagged with "string:" (the tag will be removed during compilation, it's needed because there's no reliable way to detect that a variable contains a string), and it will automatically use cache_get_value_name for them, and anything else will use cache_get_value_index.
I barely know the concept so I might be a bit wrong, but that's the basic concept and it works!
https://github.com/pBlueG/SA-MP-MySQL/bl...#L185-L189
The thing with tags is that it allows you to define more than one macro replacement for a function (it is technically recognized as different because of the tags). This example macro will match a literal string and variables tagged with "string:" (the tag will be removed during compilation, it's needed because there's no reliable way to detect that a variable contains a string), and it will automatically use cache_get_value_name for them, and anything else will use cache_get_value_index.
I barely know the concept so I might be a bit wrong, but that's the basic concept and it works!