Skip to content

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

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

[feature request] Character separated list #680

Closed
StarlightIbuki opened this issue Aug 3, 2022 · 1 comment
Closed

[feature request] Character separated list #680

StarlightIbuki opened this issue Aug 3, 2022 · 1 comment

Comments

@StarlightIbuki
Copy link

Could we have a grammar for that?
Something similar to this:

arguments = { argument * "," }
ipv4 = @{ ASCII_DIGIT{1,3} {3} "." }

(There should be better design but this is just an illustration.)

@huacnlee
Copy link
Member

huacnlee commented Feb 10, 2023

ipv4 = @{ (code ~ "."){3} ~ code }
code = @{ ASCII_DIGIT{1,3} }

If we input: 127.0.0.1 then will get:

- ipv4: "127.0.0.1"

@pest-parser pest-parser locked and limited conversation to collaborators Feb 11, 2023
@tomtau tomtau converted this issue into discussion #798 Feb 11, 2023

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

Projects
None yet
Development

No branches or pull requests

3 participants