minit: do not misdetect files suffixed as "" or named "." or "c" or "s" as c#

You cannot `str() in str()` and expect it to act like `str() in list()`.

Fixes regression in commit bbc2745dcc
Unbreaks #6573
Fixes #8872
pull/8873/head
Eli Schwartz 3 years ago
parent 15fb6a407f
commit 0c7cdb1862
No known key found for this signature in database
GPG Key ID: CEB167EFB5722BD6
  1. 2
      mesonbuild/minit.py

@ -105,7 +105,7 @@ def autodetect_options(options: 'argparse.Namespace', sample: bool = False) -> N
if f.suffix in ('.cc', '.cpp'):
options.language = 'cpp'
break
if f.suffix in '.cs':
if f.suffix == '.cs':
options.language = 'cs'
break
if f.suffix == '.cu':

Loading…
Cancel
Save