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

Cannot format zeek-7 IDs in global scope #83

Open
bbannier opened this issue Aug 5, 2024 · 1 comment
Open

Cannot format zeek-7 IDs in global scope #83

bbannier opened this issue Aug 5, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@bbannier
Copy link
Member

bbannier commented Aug 5, 2024

zeek-7 changed the way global IDs are written from GLOBAL::XYZ to ::XYZ. This syntax is not supported by e.g., zeek-format.

type r: record { };

event zeek_init()
	{
	local x: ::r;
	}
$ zeek-format foo.zeek
cannot parse line 5, col 9: ": :"
type r: record { };

event zeek_init()
        {
        local x : : : r;
        }
@bbannier bbannier added the bug Something isn't working label Aug 5, 2024
@bbannier
Copy link
Member Author

bbannier commented Aug 5, 2024

I filed a PR to fix the grammar part of this, zeek/tree-sitter-zeek#28. This still requires changes to zeek-format which even with the adjusted grammar seems to insist on inserting too many spaces.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant