From a92b14426027a893a6e03e42383693a637e2c1c0 Mon Sep 17 00:00:00 2001 From: pfg Date: Sun, 3 Oct 2021 16:27:12 -0400 Subject: [PATCH] switch back to peg for the grammar type --- doc/docgen.zig | 6 +++--- doc/langref.html.in | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/doc/docgen.zig b/doc/docgen.zig index 4e4926d65c..0f6aacb465 100644 --- a/doc/docgen.zig +++ b/doc/docgen.zig @@ -313,7 +313,7 @@ const SyntaxBlock = struct { const SourceType = enum { zig, c, - y, + peg, javascript, }; }; @@ -667,8 +667,8 @@ fn genToc(allocator: *Allocator, tokenizer: *Tokenizer) !Toc { source_type = SyntaxBlock.SourceType.zig; } else if (mem.eql(u8, source_type_str, "c")) { source_type = SyntaxBlock.SourceType.c; - } else if (mem.eql(u8, source_type_str, "y")) { - source_type = SyntaxBlock.SourceType.y; + } else if (mem.eql(u8, source_type_str, "peg")) { + source_type = SyntaxBlock.SourceType.peg; } else if (mem.eql(u8, source_type_str, "javascript")) { source_type = SyntaxBlock.SourceType.javascript; } else { diff --git a/doc/langref.html.in b/doc/langref.html.in index 516e6775a9..310675a9ff 100644 --- a/doc/langref.html.in +++ b/doc/langref.html.in @@ -170,7 +170,7 @@ background: #a8b9cc; color: #000; } - figcaption.y-cap { + figcaption.peg-cap { background: #fcdba5; } figcaption.javascript-cap { @@ -291,7 +291,7 @@ background-color: #b27306; color: #000; } - figcaption.y-cap { + figcaption.peg-cap { background-color: #b27306; color: #000; } @@ -11657,7 +11657,7 @@ fn readU32Be() u32 {} {#header_close#} {#header_open|Grammar#} - {#syntax_block|y|grammar.y#}Root <- skip container_doc_comment? ContainerMembers eof + {#syntax_block|peg|grammar.y#}Root <- skip container_doc_comment? ContainerMembers eof # *** Top level *** ContainerMembers <- ContainerDeclarations (ContainerField COMMA)* (ContainerField / ContainerDeclarations)