mirror of
https://github.com/pragma-/pbot.git
synced 2024-12-24 11:42:35 +01:00
compiler_vm: fix interwined comments losing first ; after // (#60)
This commit is contained in:
parent
76479ed8cf
commit
e00ba2e62f
@ -352,7 +352,7 @@ sub preprocess_code {
|
|||||||
$self->{code} =~ s/\s+$//;
|
$self->{code} =~ s/\s+$//;
|
||||||
$self->{code} =~ s/;\s*;\n/;\n/gs;
|
$self->{code} =~ s/;\s*;\n/;\n/gs;
|
||||||
$self->{code} =~ s/;(\s*\/\*.*?\*\/\s*);\n/;$1/gs;
|
$self->{code} =~ s/;(\s*\/\*.*?\*\/\s*);\n/;$1/gs;
|
||||||
$self->{code} =~ s/;(\s*\/\/.*?\s*);\n/;$1/gs;
|
$self->{code} =~ s/;(\s*\/\/.*?\s*);\n/;$1;/gs;
|
||||||
$self->{code} =~ s/(\{|})\n\s*;\n/$1\n/gs;
|
$self->{code} =~ s/(\{|})\n\s*;\n/$1\n/gs;
|
||||||
$self->{code} =~ s/(?:\n\n)+/\n\n/g;
|
$self->{code} =~ s/(?:\n\n)+/\n\n/g;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user