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

Revert "Multiline comments" - accidentally merged #1287

Merged
merged 1 commit into from
Feb 29, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions src/diagrams/class/parser/classDiagram.jison
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,7 @@
%x string generic struct

%%
\%\%[^\n]*\n* /* skip comments */
\%\%\*((.|\n)*)\*\%\% /* multiline skip comments */
\%\%[^\n]*\n* /* do nothing */
\n+ return 'NEWLINE';
\s+ /* skip whitespace */
"classDiagram" return 'CLASS_DIAGRAM';
Expand Down
3 changes: 1 addition & 2 deletions src/diagrams/flowchart/parser/flow.jison
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,7 @@
%x dir
%x vertex
%%
\%\%[^\n]*\n* /* skip comments */
\%\%\*((.|\n)*)\*\%\% /* multiline skip comments */
\%\%[^\n]*\n* /* do nothing */
["] this.begin("string");
<string>["] this.popState();
<string>[^"]* return "STR";
Expand Down
1 change: 0 additions & 1 deletion src/diagrams/gantt/parser/gantt.jison
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
\s+ /* skip whitespace */
\#[^\n]* /* skip comments */
\%%[^\n]* /* skip comments */
\%\%\*((.|\n)*)\*\%\% /* multiline skip comments */

/*
---interactivity command---
Expand Down
1 change: 0 additions & 1 deletion src/diagrams/git/parser/gitGraph.jison
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@
\s+ /* skip all whitespace */
\#[^\n]* /* skip comments */
\%%[^\n]* /* skip comments */
\%\%\*((.|\n)*)\*\%\% /* multiline skip comments */
"gitGraph" return 'GG';
"commit" return 'COMMIT';
"branch" return 'BRANCH';
Expand Down
3 changes: 1 addition & 2 deletions src/diagrams/pie/parser/pie.jison
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,7 @@
%}

%%
\%\%[^\n]* /* skip comments */
\%\%\*((.|\n)*)\*\%\% /* multiline skip comments */
\%\%[^\n]* /* do nothing */
\s+ /* skip whitespace */
"pie" return 'pie' ;
[\s\n\r]+ return 'NL' ;
Expand Down
1 change: 0 additions & 1 deletion src/diagrams/sequence/parser/sequenceDiagram.jison
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@
<ID,ALIAS,LINE>((?!\n)\s)+ /* skip same-line whitespace */
<INITIAL,ID,ALIAS,LINE>\#[^\n]* /* skip comments */
\%%[^\n]* /* skip comments */
\%\%\*((.|\n)*)\*\%\% /* multiline skip comments */
"participant" { this.begin('ID'); return 'participant'; }
<ID>[^\->:\n,;]+?(?=((?!\n)\s)+"as"(?!\n)\s|[#\n;]|$) { yytext = yytext.trim(); this.begin('ALIAS'); return 'ACTOR'; }
<ALIAS>"as" { this.popState(); this.popState(); this.begin('LINE'); return 'AS'; }
Expand Down
5 changes: 2 additions & 3 deletions src/diagrams/state/parser/stateDiagram.jison
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,10 @@
%%

[\n]+ return 'NL';
\s+ /* skip all whitespace */
\s+ /* skip all whitespace */
<ID,STATE,struct,LINE>((?!\n)\s)+ /* skip same-line whitespace */
<INITIAL,ID,STATE,struct,LINE>\#[^\n]* /* skip comments */
\%%[^\n]* /* skip comments */
\%\%\*((.|\n)*)\*\%\% /* multiline skip comments */
\%%[^\n]* /* skip comments */

"scale"\s+ { this.pushState('SCALE'); /* console.log('Got scale', yytext);*/ return 'scale'; }
<SCALE>\d+ return 'WIDTH';
Expand Down