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

Language specific string delimiters #2119

Merged
merged 2 commits into from
Feb 7, 2023
Merged

Conversation

sthilaid
Copy link
Contributor

@sthilaid sthilaid commented Feb 7, 2023

Added 'stdStringStartEnd' option in tic_script_config to allow language to define their tokens to start/end strings.

@sthilaid
Copy link
Contributor Author

sthilaid commented Feb 7, 2023

@AlecTroemel, this might interest you too since I suspect that Janet must also use single quotes for quoting and not starting strings. There might be other languages variations, but I don't know really the other languages (fennel?)

@AlecTroemel
Copy link
Contributor

@sthilaid not exactly sure what you mean by "must also use single quotes for quoting and not starting strings."

Though Janet strings can use ', ", or any number of backticks `. That last one may throw a wrench into the changes here

https://janet-lang.org/docs/strings.html

@sthilaid
Copy link
Contributor Author

sthilaid commented Feb 7, 2023

@AlecTroemel , okay, yes that's why I'm asking! Janet looks like another lisp dialect but clearly has it's quirks! ;p But you could add backquotes as a string starter with this change.

@sogaiu
Copy link

sogaiu commented Feb 7, 2023

I think Fennel folks might be interested too :)

May be @technomancy ?

@sthilaid
Copy link
Contributor Author

sthilaid commented Feb 7, 2023

They probably will also be interested in the structured edition changes too then: #2117

@sogaiu
Copy link

sogaiu commented Feb 7, 2023

He he, beat me to posting it :)

@technomancy
Copy link
Contributor

Cool, thanks! Fennel can have the same rule applied as Scheme; we only use double-quotes and never single-quotes.

I had considered working on adding structural editing to TIC; I probably would have done it years ago if the editor had been written in Lua or a language that has real strings, but I never imagined someone would have actually pulled it off in C. Amazing.

@sthilaid
Copy link
Contributor Author

sthilaid commented Feb 7, 2023 via email

@nesbox nesbox merged commit 74a1497 into nesbox:main Feb 7, 2023
@sthilaid sthilaid deleted the editor-upgrade branch February 27, 2023 02:50
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.

5 participants