Skip to content

[C++] Add arrow::compute::Expression::Equals option that does not compare kernels #36427

@westonpace

Description

@westonpace

Describe the enhancement requested

This would allow an unbound expression to be considered equal to a bound expression as long as they represent the same call (e.g. same number of arguments, same function name, etc.)

When binding we also do some slight massaging of types (e.g. add(foo_i8, 7_i64) converts to add(foo_i8, 7_i8)). This method should not try and correct for that (e.g. those two example expressions would still be considered unequal). It should mainly just avoid looking at the Call::kernel field and the field reference types and function types.

Once this is added we should enhance the test_expression_serialization test in test_compute.py to use Expression::Equals instead of comparing the string representation of expressions.

Component(s)

C++

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions