mirror of
https://github.com/ziglang/zig.git
synced 2025-12-06 06:13:07 +00:00
autodoc: Added line_comment tokens to ziglexer.js tokenizer
This commit is contained in:
parent
c4e62be62e
commit
b317ca4d6f
@ -836,7 +836,8 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.zig_doc_comment,
|
.zig_doc_comment,
|
||||||
.zig_container_doc_comment {
|
.zig_container_doc_comment,
|
||||||
|
.zig_line_comment {
|
||||||
color: #545454;
|
color: #545454;
|
||||||
font-style: italic;
|
font-style: italic;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -12,6 +12,7 @@ const Tag = {
|
|||||||
number_literal: "number_literal",
|
number_literal: "number_literal",
|
||||||
doc_comment: "doc_comment",
|
doc_comment: "doc_comment",
|
||||||
container_doc_comment: "container_doc_comment",
|
container_doc_comment: "container_doc_comment",
|
||||||
|
line_comment: "line_comment",
|
||||||
invalid_periodasterisks: "invalid_periodasterisks",
|
invalid_periodasterisks: "invalid_periodasterisks",
|
||||||
bang: "bang",
|
bang: "bang",
|
||||||
pipe: "pipe",
|
pipe: "pipe",
|
||||||
@ -1699,9 +1700,9 @@ function InnerTokenizer(raw_source) {
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
case '\n': {
|
case '\n': {
|
||||||
state = State.start;
|
result.tag = Tag.line_comment;
|
||||||
result.loc.start = this.index + 1;
|
result.loc.end = this.index;
|
||||||
break;
|
return result;
|
||||||
}
|
}
|
||||||
case '\t': break;
|
case '\t': break;
|
||||||
//TODO: PORT
|
//TODO: PORT
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user