Commit 2605ab5c authored by Alexander Shursha's avatar Alexander Shursha Committed by Franco Fichtner

template: change Volt parsing

parent ec241127
...@@ -19,7 +19,7 @@ sub extract { ...@@ -19,7 +19,7 @@ sub extract {
# Volt Template: # Volt Template:
$line = 1; $line = 1;
pos($_) = 0; pos($_) = 0;
while (m/\G(.*?(?<!\{)\{\{(?!\{)\s*lang\._\('(.*?)'\)\s*?\|?.*?\}\})/sg) { while (m/\G(.*?(?<!\{)\{\{(?!\{).*?lang\._\('(.*?)'\).*?\|?.*?\}\})/sg) {
my ( $vars, $str ) = ( '', $2 ); my ( $vars, $str ) = ( '', $2 );
$line += ( () = ( $1 =~ /\n/g ) ); # cryptocontext! $line += ( () = ( $1 =~ /\n/g ) ); # cryptocontext!
$self->add_entry( $str, $line, $vars ); $self->add_entry( $str, $line, $vars );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment