diff options
author | Eli Schwartz <eschwartz@archlinux.org> | 2021-03-04 17:02:02 -0500 |
---|---|---|
committer | Eli Schwartz <eschwartz@archlinux.org> | 2021-03-04 17:09:00 -0500 |
commit | 76df995ba69ef5d790462856b3edbd42b28b906a (patch) | |
tree | 1acab97d1dc34ffa16d0fb723346675184f649c3 /mesonbuild/mcompile.py | |
parent | fb595294587a70ae67622b5c03a9d3e46a37d4fa (diff) | |
download | meson-76df995ba69ef5d790462856b3edbd42b28b906a.zip meson-76df995ba69ef5d790462856b3edbd42b28b906a.tar.gz meson-76df995ba69ef5d790462856b3edbd42b28b906a.tar.bz2 |
raw string literals are next to godliness
Invalid escape sequences are deprecated and will be removed from a
future version of python. Use r"" to define them so they remain
readable.
Diffstat (limited to 'mesonbuild/mcompile.py')
-rw-r--r-- | mesonbuild/mcompile.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mesonbuild/mcompile.py b/mesonbuild/mcompile.py index ba1d3cf..b7653d2 100644 --- a/mesonbuild/mcompile.py +++ b/mesonbuild/mcompile.py @@ -175,7 +175,7 @@ def generate_target_name_vs(target: ParsedTargetName, builddir: Path, introspect # Normalize project name # Source: https://docs.microsoft.com/en-us/visualstudio/msbuild/how-to-build-specific-targets-in-solutions-by-using-msbuild-exe - target_name = re.sub('[\%\$\@\;\.\(\)\']', '_', intro_target['id']) # type: str + target_name = re.sub(r"[\%\$\@\;\.\(\)']", '_', intro_target['id']) # type: str rel_path = Path(intro_target['filename'][0]).relative_to(builddir.resolve()).parent if rel_path != Path('.'): target_name = str(rel_path / target_name) |