Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add C escape sequences #1203

Merged
merged 1 commit into from
Jun 29, 2023
Merged

Add C escape sequences #1203

merged 1 commit into from
Jun 29, 2023

Conversation

czkz
Copy link
Contributor

@czkz czkz commented Jun 25, 2023

Some C escape sequences are not supported in Janet strings, namely:

  • \'
  • \?
  • \a
  • \b

Full list at https://en.cppreference.com/w/c/language/escape.
Supporting them could be useful to copy-paste strings from other languages (and I need \b).

@ml-2
Copy link
Contributor

ml-2 commented Jun 25, 2023

You probably already know this, but you can use \x08 instead of \b if you need it right now in Janet.

@bakpakin
Copy link
Member

We don't really need things like \? and \' but I suppose they don't hurt for copy pasting.

@bakpakin bakpakin merged commit b125cbe into janet-lang:master Jun 29, 2023
8 checks passed
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.

None yet

3 participants