Fix block comment
This commit is contained in:
parent
3125a2f0d4
commit
aa74032837
@ -30,7 +30,10 @@ pub(crate) fn one_line_comment(s: Span) -> IResult<Span, Comment> {
|
|||||||
#[packrat_parser]
|
#[packrat_parser]
|
||||||
pub(crate) fn block_comment(s: Span) -> IResult<Span, Comment> {
|
pub(crate) fn block_comment(s: Span) -> IResult<Span, Comment> {
|
||||||
let (s, a) = tag("/*")(s)?;
|
let (s, a) = tag("/*")(s)?;
|
||||||
let (s, b) = many0(alt((is_not("*"), terminated(tag("*"), is_not("/")))))(s)?;
|
let (s, b) = many0(alt((
|
||||||
|
is_not("*"),
|
||||||
|
terminated(tag("*"), peek(not(tag("/")))),
|
||||||
|
)))(s)?;
|
||||||
let (s, c) = tag("*/")(s)?;
|
let (s, c) = tag("*/")(s)?;
|
||||||
let mut a = a;
|
let mut a = a;
|
||||||
for b in b {
|
for b in b {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user