Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The change allows you to convert a macro (which has no args) to string.
Related to #943
Where can this be used?
In code/libraries, you can often see duplication of constants in numeric and string values (versions, parameters, etc). This creates inconvenience that one value needs to be edited in several places.
In general, if you want to quickly convert some predefined value to a string, then this can be done at the compilation stage.
A few notes:
I tried to implement "in-depth" macro parsing, but often I had to rewrite an existing function due to the inability to use custom streams. Perhaps such functionality is not needed in sp.
I also noticed that something similar had already been done in the experimental part, but for some reason it was abandoned.
imho, this is the simplest solution