Skip to content
This repository has been archived by the owner on Nov 5, 2021. It is now read-only.

Pascal language support #60

Merged
merged 5 commits into from
Mar 4, 2019
Merged

Pascal language support #60

merged 5 commits into from
Mar 4, 2019

Conversation

alefragnani
Copy link
Contributor

@alefragnani alefragnani commented Jan 13, 2019

Adds basic Pascal language support, with syntax highlighting, auto-closing pairs and code folding.

@ALANVF
Copy link
Contributor

ALANVF commented Jan 15, 2019

You kinda messed up on the escape sequences; Pascal doesn't have any. Add a #\d+ rule for control strings (the pascal equivalent of escape sequences, but they aren't in strings). If you're still confused, maybe look at this

@alefragnani
Copy link
Contributor Author

Hi @ALANVF ,

You are right. I ended up forgetting to remove/update that escapes rule 👍 . The only real escape would be ', when close to another '.

About the \#d+ rule for control string, I’m not so sure if it should be added, because #27 Can represent an hex number or the chr(27) string, depending on where it is being used.

I’ll update the PR with your comments, thank you 👍

@ALANVF
Copy link
Contributor

ALANVF commented Jan 16, 2019

No problem, I'm suprised I caught it. As for the control string, maybe you can make a rule to highlight it if it is placed next to a string, or just highlight it anyways since it means something special either way.

@alefragnani
Copy link
Contributor Author

Ops, my bad, wrong special char for hex number on my previous comment....

#27 is not an hex number, but $27 (with $).

But \#d+ is not enough, because it can repeat multiple times, like #13#10#13#10#9 for instance. This pattern, is not something that I use very often, actually. That's may be the reason that I totally forgot about it 😞 .

I'll fix/remove the escapes rules first, and take a look to update this #string latter.

Thank you

@alexdima
Copy link
Member

alexdima commented Mar 4, 2019

👍 Thank you

@alexdima alexdima added this to the February 2019 milestone Mar 4, 2019
@alexdima alexdima merged commit 8612cdf into microsoft:master Mar 4, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
3 participants