Dylan Baker
abababfb93
interpreterobjects: fix Test annotations
3 years ago
Xavier Claessens
8c5aa031b5
Add install tags
...
Fixes : #7007 .
3 years ago
Dylan Baker
272674e792
interpreter/compiler: make helper methods protected
3 years ago
Dylan Baker
b30dddd4e5
interpreter/compiler: Add type checking for the Compiler object
...
This adds a full set of `typed_pos_args` and `typed_kwarg` decorations,
as well as fixing all of the typing errors reported by mypy.
3 years ago
Dylan Baker
bcb5400e34
interpreter/compiler: Add type annotations to TryRunResultHolder
3 years ago
Dylan Baker
7dda90f1bf
interpreter/compiler: remove unittest_args method
...
It's not documented, and it's been marked deprecated for who knows how
long.
3 years ago
Dylan Baker
32d3b5c9e2
interpreter/compiler: Replace permittedKwargs({}) with noKwargs
...
The former isn't really correct, as it wants a set and is getting a
dict, the other is also conceptually clearer I think.
3 years ago
Dylan Baker
a1fb3199c8
interpreterobjects: Add TypedDict annoations for `extract_search_dirs`
...
This allows for more accurate type checking
3 years ago
Dylan Baker
aca2192471
interpreter: fix `source_strings_to_files` annotations
...
It's missing a required overload declaration
3 years ago
Tristan Partin
1dc13e9951
Add unset_variable()
...
This should be useful for helping to control variable scope within
Meson. CMake has something similar for controlling scope.
3 years ago
Xavier Claessens
a2f110ff77
interpreter: Fix holder_map not being updated when subproject fails
...
Fixes : #9038
3 years ago
Jussi Pakkanen
3340d373fb
Revert "interpreter: Fix holder_map not being updated when subproject fails"
...
This reverts commit 566383c727
.
3 years ago
Xavier Claessens
27b319526c
interpreter: Fix spurious warning in configure_data()
...
This is a regression when porting to typed_pos_args().
3 years ago
Xavier Claessens
5462ea921f
interpreter: Fix missing subsubproject summary when subproject fails
...
In the case main->subp->subsubp, if subsubp succeed to configure but
subp subsequentially fails, subsubp is still being built but its summary
was missing.
3 years ago
Xavier Claessens
566383c727
interpreter: Fix holder_map not being updated when subproject fails
...
Fixes : #9038
3 years ago
Xavier Claessens
943596abbb
Fix --force-fallack-for with --wrap-mode=nofallback
...
Fixes : #9065
4 years ago
Felix Schwarz
53ce1610a6
fix spelling error in user output ("depencency" -> "dependency")
4 years ago
Dylan Baker
f4a1da0145
interpreterbase/decorators: use a named function for lowering strings
...
Mypy gets confused by the lambda, so we might as well just use a named
function.
4 years ago
Dylan Baker
2307cbd2ac
interpreter/typing: Add some type annotations
...
We really need PEP464 to annotate many fo thse correctly, but until then
we can manually annotate many of them to fix typing issues.
4 years ago
Dylan Baker
d1b52b913f
interpreter: split keyword definitions out of the interpreter
4 years ago
Xavier Claessens
0183954ea1
Fix meson.version().version_compare() regression in subproject
4 years ago
Dylan Baker
a881e849b5
modules/python: simplify a number of interfaces
...
Including not calling back into `Interpreter.func_*`, which is not a
good idea both from a type saftey and perforamance point of view.
Instead there's now a shared _impl method
4 years ago
Dylan Baker
f459c0e918
interpreter: remove stringArgs uses
...
It's only used now on a files that always raises an exception anyway,
might as well just not do any checking and reduces the uses of that
function
4 years ago
Dylan Baker
52c68ca6fe
interpreter: use typed_pos_args for files
4 years ago
Dylan Baker
011f13bcdc
interpreter: use typed_pos_args for add_langauges
4 years ago
Dylan Baker
011b58d75f
interpreter: use typed_pos_args for project
4 years ago
Dylan Baker
015e44014a
interpreter: use typed_pos_args for subdir
4 years ago
Dylan Baker
3f6afa2693
interpreter: use typed_pos_args for assert
4 years ago
Dylan Baker
2486938011
interpreter: use typed_pos_args for subproject
4 years ago
Dylan Baker
9f07a1ad41
interpreter: use typed_pos_args for get_option
4 years ago
Dylan Baker
6f6db0f2e3
interpreter: use typed_pos_args configuration_data
4 years ago
Dylan Baker
982973f303
interpreter: use typed_pos_args for alias_target
4 years ago
Dylan Baker
09d7da19c1
interpreter: use typed_kwargs for include_directories
4 years ago
Dylan Baker
3135b130b8
interpreter: use typed_pos_args for include_directories
4 years ago
Dylan Baker
5aed9dd939
interpreter: use typed_pos_args for add_test_setup
4 years ago
Dylan Baker
e71a6544c5
interpreter: use typed_pos_args for join_paths
4 years ago
Dylan Baker
9ecd578167
interpreter: use typed_pos_args for set_variable
4 years ago
Dylan Baker
20c5dfe869
interpreter: use typed_pos_args for get_variable
4 years ago
Dylan Baker
4d05f9d64b
interpreter: use typed_pos_args for is_variable
4 years ago
Dylan Baker
30a9bb60ee
interpreter: use typed_pos_args for is_disabler
4 years ago
Eli Schwartz
bd6f46e723
condense lines
4 years ago
Eli Schwartz
dd31891c1f
more f-strings too complex to be caught by pyupgrade
4 years ago
Eli Schwartz
c4f5f6364e
pyupgrade
4 years ago
Tristan Partin
6f3f43bb2d
Flatten test suite value
...
This behavior is more inline with the rest of Meson
4 years ago
Daniel Mensinger
971a0b1775
fix: get_variable default variables are not ObjectHolders ( fixes #8936 )
4 years ago
Dylan Baker
bc4201a7f1
interpreter: add required and disabled to import
...
This is useful both from the perspective of optional functionality that
requires a module, and also as I continue to progress with Meson++,
which will probably not implement all of the modules that Meson itself
does.
4 years ago
Dylan Baker
4a0a6a8083
modules: modules need to return either an ExtensionModlue or a
...
NewExtensionModule object
So that we get the found() method.
4 years ago
Dylan Baker
351a1e9ec9
interpreter: use typed_pos_args for func_import
...
and make the helper method private
4 years ago
Simon Ser
1f3adc4dbe
Add feed arg to custom_target()
4 years ago
Daniel Mensinger
3e396b3782
fix: Always explicitly set encoding for text files ( fixes #8263 )
4 years ago