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

Checking in string constants fails for elm, Haskell, & PureScript #598

Open
mzero opened this issue Jan 29, 2025 · 0 comments
Open

Checking in string constants fails for elm, Haskell, & PureScript #598

mzero opened this issue Jan 29, 2025 · 0 comments

Comments

@mzero
Copy link

mzero commented Jan 29, 2025

All three languages, elm, haskell, purescript have standard style quoted strings using double quotes:

"I am a string with a speeling misteek."

elm and purescript also support multi-line strings with triple quotes:

"""
If monads are like burrrritos
Can I put salza on them?
"""

All three languages are described by one entry in lib/doctype.js:

        case 'elm':
        case 'haskell':
        case 'purescript':
            return new Code_1.default({ comment_start: '{-', comment_end: '-}', comment_line: '--' });

But that entry only describes comments. That entry probably needs to be split into two (one for elm & purescript, one for haskell) - like so:

        case 'elm':
        case 'purescript':
            return new Code_1.default({ comment_start: '{-', comment_end: '-}', comment_line: '--', string_inline: '"', string_quote: '\\', string_multiline: '"""'});
        case 'haskell':
            return new Code_1.default({ comment_start: '{-', comment_end: '-}', comment_line: '--', string_inline: '"', string_quote: '\\'});

I would test that... but don't have the environment to build and test VCS extensions.

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

No branches or pull requests

1 participant