Fixing reserve word NULL for cpp targets#3889
Conversation
Signed-off-by: 1sand0s <1sand0sardpi@gmail.com>
There was a problem hiding this comment.
Please add new or extend the existing test ReservedWordsEscaping.txt that covers suggested changes.
bf5e884 to
b20db8c
Compare
I had not though about this, but I guess some of the fix PRs did not have one fix that was in the legacy version of the runtime, copied in to the v4 branch. This commit fixes that. Signed-off-by: Jim.Idle <jimi@gatherstars.com> Signed-off-by: 1sand0s <1sand0sardpi@gmail.com>
Signed-off-by: Terence Parr <parrt@antlr.org> Signed-off-by: 1sand0s <1sand0sardpi@gmail.com>
Signed-off-by: Terence Parr <parrt@antlr.org> Signed-off-by: 1sand0s <1sand0sardpi@gmail.com>
Signed-off-by: 1sand0s <1sand0sardpi@gmail.com>
Signed-off-by: Terence Parr <parrt@antlr.org> Signed-off-by: 1sand0s <1sand0sardpi@gmail.com>
Signed-off-by: 1sand0s <1sand0sardpi@gmail.com>
Signed-off-by: 1sand0s <1sand0sardpi@gmail.com>
Signed-off-by: 1sand0s <1sand0sardpi@gmail.com>
Signed-off-by: 1sand0s <1sand0sardpi@gmail.com>
Signed-off-by: 1sand0s <1sand0sardpi@gmail.com>
Signed-off-by: 1sand0s <1sand0sardpi@gmail.com>
Signed-off-by: 1sand0s <1sand0sardpi@gmail.com>
515dc16 to
d26c064
Compare
|
Could you please get rid of unrelated commits (using interactive rebase)? Some changes are unrelated to the topic. |
Signed-off-by: 1sand0s <1sand0sardpi@gmail.com>
Signed-off-by: 1sand0s <1sand0sardpi@gmail.com>
Signed-off-by: 1sand0s <1sand0sardpi@gmail.com>
Signed-off-by: 1sand0s <1sand0sardpi@gmail.com>
Signed-off-by: 1sand0s <1sand0sardpi@gmail.com>
Signed-off-by: 1sand0s <1sand0sardpi@gmail.com>
…thub.com/1sand0s/antlr4 into Fixing_Reserve_Word_NULL_for_Cpp_Targets
@KvanTTT Done ! |
@KvanTTT Just a reminder that I have removed unrelated commits. Thanks ! |
|
I see unrelated commits anyway. @parrt the changes look good to me, but I suggest squashing all commits since most of them are useless. |
|
Looks like we have a merge conflict. Can you take a look / rebase? |
@parrt I compared the |
|
AH. it was set at rebase not merge. A merge will work. thanks! |
PR Summary
NULLwhich is a reserve word inCpp. This PR addsNULLto the list of reserve words inCppTarget.java.Stringarguments ofgetTargetStringLiteralFromStringandgetTargetStringLiteralFromANTLRStringLiteralinTarget.java,sandliteralrespectively, toTarget'sescapeIfNeededfunction since potential reserve words must be handled before being accumulated into the StringBuildersg.tokenNameToTypeMapinRecognizertoTarget'sescapeIfNeededfunction before being inserted intotokensinRecognizerBest