mirror of
https://github.com/iluvcapra/ptulsconv.git
synced 2025-12-31 08:50:48 +00:00
Fixed regex statements in parser
This clears up a bunch of `DeprecationWarning`s in pytest
This commit is contained in:
@@ -67,8 +67,8 @@ protools_text_export_grammar = Grammar(
|
||||
fs = "\t"
|
||||
rs = "\n"
|
||||
block_ending = rs rs
|
||||
string_value = ~"[^\t\n]*"
|
||||
integer_value = ~"\d+"
|
||||
float_value = ~"\d+(\.\d+)?"
|
||||
isp = ~"[^\d\t\n]*"
|
||||
string_value = ~r"[^\t\n]*"
|
||||
integer_value = ~r"\d+"
|
||||
float_value = ~r"\d+(\.\d+)?"
|
||||
isp = ~r"[^\d\t\n]*"
|
||||
""")
|
||||
|
||||
@@ -18,11 +18,11 @@ tag_grammar = Grammar(
|
||||
key_tag = "[" key "]" word_sep?
|
||||
short_tag = "$" key "=" word word_sep?
|
||||
full_text_tag = "{" key "=" value "}" word_sep?
|
||||
key = ~"[A-Za-z][A-Za-z0-9_]*"
|
||||
value = ~"[^}]+"
|
||||
key = ~r"[A-Za-z][A-Za-z0-9_]*"
|
||||
value = ~r"[^}]+"
|
||||
tag_junk = word word_sep?
|
||||
word = ~"[^ \[\{\$][^ ]*"
|
||||
word_sep = ~" +"
|
||||
word = ~r"[^ \[\{\$][^ ]*"
|
||||
word_sep = ~r" +"
|
||||
modifier = ("@" / "&") word_sep?
|
||||
"""
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user