summaryrefslogtreecommitdiff
path: root/test cases/failing
diff options
context:
space:
mode:
authorDylan Baker <dylan@pnwbakers.com>2025-12-08 10:53:08 -0800
committerDylan Baker <dylan@pnwbakers.com>2025-12-17 12:46:50 -0800
commitbde1c23b4f3eb9eb63e835b722bb9bbcccc4c8c1 (patch)
tree3f7ef84071483aa7cdca5337615ea2259180b172 /test cases/failing
parentf3d9a71a1bea661495c1d3c6004b26b4497fb1c9 (diff)
downloadmeson-bde1c23b4f3eb9eb63e835b722bb9bbcccc4c8c1.tar.gz
interpreter|build: Use typed_kwargs for build_target(dependencies)
What is basically impossible is to handle `SubprojectHolder`, because it's not a true holder but an interpreter object. Well, impossible without changing SubprojectHolder into a true holder, because it's avoiding the circular import becomes extremely convoluted otherwise, and refactoring is difficult because the held object is itself an Interpreter. It's a rather complex problem to solve gracefully. I've punted to avoid the complexity, it does mean that the error message is somewhat less exact. I don't think this is actually a huge problem because we've really guided people away from using `subproject()` and to instead use dependency fallbacks, which don't have this problem to begin with. This removes validation from the build layer, and puts it in interpreter. For code sharing reasons this means that `internal_dependency` also gets more fine grained error messages. The test case for this has been modified to use the `testcase expect_error` construct, and thus has been moved to the common tests directory. It's also been extended to cover both the library case, which gives coverage for the `extra_types` in `KwargInfo`
Diffstat (limited to 'test cases/failing')
-rw-r--r--test cases/failing/124 subproject object as a dependency/main.c1
-rw-r--r--test cases/failing/124 subproject object as a dependency/meson.build4
-rw-r--r--test cases/failing/124 subproject object as a dependency/subprojects/sub/meson.build1
-rw-r--r--test cases/failing/124 subproject object as a dependency/test.json7
4 files changed, 0 insertions, 13 deletions
diff --git a/test cases/failing/124 subproject object as a dependency/main.c b/test cases/failing/124 subproject object as a dependency/main.c
deleted file mode 100644
index 78f2de106..000000000
--- a/test cases/failing/124 subproject object as a dependency/main.c
+++ /dev/null
@@ -1 +0,0 @@
-int main(void) { return 0; }
diff --git a/test cases/failing/124 subproject object as a dependency/meson.build b/test cases/failing/124 subproject object as a dependency/meson.build
deleted file mode 100644
index 0114b9a31..000000000
--- a/test cases/failing/124 subproject object as a dependency/meson.build
+++ /dev/null
@@ -1,4 +0,0 @@
-project('test', 'c')
-
-executable(
- 'main', 'main.c', dependencies: subproject('sub'))
diff --git a/test cases/failing/124 subproject object as a dependency/subprojects/sub/meson.build b/test cases/failing/124 subproject object as a dependency/subprojects/sub/meson.build
deleted file mode 100644
index 0adfd6a6e..000000000
--- a/test cases/failing/124 subproject object as a dependency/subprojects/sub/meson.build
+++ /dev/null
@@ -1 +0,0 @@
-project('sub')
diff --git a/test cases/failing/124 subproject object as a dependency/test.json b/test cases/failing/124 subproject object as a dependency/test.json
deleted file mode 100644
index a0eea225f..000000000
--- a/test cases/failing/124 subproject object as a dependency/test.json
+++ /dev/null
@@ -1,7 +0,0 @@
-{
- "stdout": [
- {
- "line": "test cases/failing/124 subproject object as a dependency/meson.build:3:0: ERROR: Tried to use subproject object as a dependency."
- }
- ]
-}