feat: add unary expressions#175
Merged
Merged
Conversation
Codecov Report❌ Patch coverage is 📢 Thoughts on this report? Let us know! |
Replace the 1013-line expression_node.cpp with one .cpp per node class (ExpressionFile, Scalar, Binary, Unary, Ternary, Aggregate, AggregateAgents, SelectAgents, RenameAgents) plus a shared expression_helpers.h holding the broadcast/validation/aggregation helpers previously in an anonymous namespace. Mechanical refactor: no behavior change, all 7 test suites pass unchanged. Also fix a pre-existing C2375 linkage mismatch by adding QUIVER_API to friend declarations in expression.h. The friends were declared without the DLL attribute while the matching free function decls had QUIVER_API; MSVC /permissive- rejects this. The mismatch was introduced when friend decls replaced the public node() accessor, and was masked until now by stale incremental build state. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Replace string operation names with typed enums across C++, C API, and Julia binding for Expression::aggregate and aggregate_agents: C++: - Expression::aggregate signature: (string, string, optional<double>) -> (string, ExpressionAggregate::Operation, optional<double>) - Expression::aggregate_agents signature: (string, optional<double>) -> (ExpressionAggregateAgents::Operation, optional<double>) - Delete the static parse_operation methods on both aggregate classes - Delete unused parse_aggregation_operation_name template from expression_helpers.h C API: - Add quiver_expression_aggregate_operation_t and quiver_expression_aggregate_agents_operation_t (5 values each: SUM/MEAN/MIN/MAX/PERCENTILE) - Switch quiver_expression_aggregate and _aggregate_agents to take the new enum types - Add from_c() converters mirroring the existing dispatch() pattern Julia binding: - Tests reference Quiver.C.QUIVER_EXPRESSION_AGGREGATE_OPERATION_* directly - Regenerate c_api.jl via generator.bat Tests: - Update 20 C++ + 16 C + 22 Julia callsites - Delete three negative tests now compile-time-safe (unknown-op string and null-op pointer) Output labels in ExpressionAggregateAgents (e.g., "sum", "mean") remain strings derived via aggregation_operation_label<Op>() — that template is still consumed and kept. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.