Skip to content

Reject apply-trait queries on an incomplete pack or copack - #443

Merged
Bronek merged 1 commit into
mainfrom
bronek/incomplete_apply_operand
Sep 29, 2026
Merged

Bronek merged 1 commit into
mainfrom
bronek/incomplete_apply_operand

Conversation

@Bronek

@Bronek Bronek commented Sep 28, 2026

Copy link
Copy Markdown
Member

Reject apply trait queries on incomplete pack or copack operands. Previously, a query could cache false or void even after the defining header was included. Include <fn/pack.hpp> or <fn/copack.hpp> before querying.

typelist_applicable still works from template arguments alone. Compilation failures cannot yet be tested in the suite; document the untested negative beside its positive controls.

Assisted-by: Claude:claude-opus-5-5
Assisted-by: Codex:gpt-6-astra

@Bronek
Bronek added this pull request to stack #445 September 28, 2026 20:14
@augmentcode

augmentcode Bot commented Sep 28, 2026

Copy link
Copy Markdown
🤖 Augment PR Summary

Summary: This PR prevents apply trait queries from silently caching an inapplicable result when a pack or copack is only forward-declared.
Changes: It adds an operand-completeness guard to result/applicability traits and documents the required include order and untestable compile-failure cases.

🤖 Was this summary useful? React with 👍 or 👎

@augmentcode augmentcode Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review completed. No suggestions at this time.

Comment augment review to trigger a new review at any time.

@Bronek
Bronek force-pushed the bronek/incomplete_apply_operand branch from 3b6e754 to 350f6c0 Compare September 28, 2026 20:38
@codecov

codecov Bot commented Sep 28, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@Bronek
Bronek force-pushed the bronek/incomplete_apply_operand branch 4 times, most recently from 1eeadd6 to 6ed28f4 Compare September 29, 2026 20:46
@Bronek
Bronek removed this pull request from stack #445 September 29, 2026 21:20
@Bronek
Bronek added this pull request to stack #446 September 29, 2026 21:21
@Bronek
Bronek removed this pull request from stack #446 September 29, 2026 21:24
@Bronek
Bronek force-pushed the bronek/incomplete_apply_operand branch from 6ed28f4 to b661fa8 Compare September 29, 2026 21:30
@Bronek
Bronek force-pushed the bronek/algebra_header branch from 671c9b2 to 52aa1fa Compare September 29, 2026 21:30
@Bronek
Bronek force-pushed the bronek/incomplete_apply_operand branch from b661fa8 to 6d2c3d0 Compare September 29, 2026 21:32
@Bronek
Bronek force-pushed the bronek/algebra_header branch 2 times, most recently from 9eefc44 to cb4a64e Compare September 29, 2026 21:34
@Bronek
Bronek force-pushed the bronek/incomplete_apply_operand branch from 6d2c3d0 to cd7c718 Compare September 29, 2026 21:34
@Bronek
Bronek changed the base branch from bronek/algebra_header to main September 29, 2026 21:36
Require complete pack and copack operands before querying their apply
members. This prevents caching a false result before the defining header
is included. Typelist queries still work from template arguments alone.

Assisted-by: Claude:claude-opus-5-5
Assisted-by: Codex:gpt-6-astra
@Bronek
Bronek force-pushed the bronek/incomplete_apply_operand branch from cd7c718 to 8f7f465 Compare September 29, 2026 21:38
@Bronek
Bronek merged commit 151f582 into main Sep 29, 2026
53 of 54 checks passed
@sonarqubecloud

Copy link
Copy Markdown

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant