Skip to content

Conversation

@LinusCenterstrom
Copy link
Collaborator

We've had issues with phrases that looks like this

_s("\"Byt artikel\" listar artiklar direkt")

since the quotes will be escaped in the source. But the backslash escaping the quote should not be a part of the phrase to translate in and of itself. This is very similar to the issue with newlines we fixed here #176

I could add more cases (for instance \t) but this is the only one I know we actually use

We've had issues with phrases that looks like this
"Byt artikel" listar artiklar direkt since the quotes will be escaped in the source. But the backslash escaping the quote should not be a part of the phrase to translate in and of itself.
This is very similar to the issue with newlines we fixed here
#176

I could add more cases (for instance \t) but this is the only one I know we actually use
This fixes a bug where the first character in the string is an escaped stringcontainer char
@LinusCenterstrom
Copy link
Collaborator Author

The initial implementation didn't work when the first character was an escaped quote for some reason. We changed the implementation to instead post-process the result which seems simpler

@LinusCenterstrom LinusCenterstrom merged commit d3d5057 into master Mar 24, 2025
2 of 4 checks passed
@LinusCenterstrom LinusCenterstrom deleted the handle-escaped-stringcontainer-in-phrase branch March 24, 2025 08:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants