Skip to content

Commit 26cd857

Browse files
committed
update upgrade guide
1 parent b88b388 commit 26cd857

1 file changed

Lines changed: 23 additions & 0 deletions

File tree

  • docs/source/library-user-guide/upgrading

‎docs/source/library-user-guide/upgrading/54.0.0.md‎

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -787,3 +787,26 @@ a combined `OR` (e.g., index-backed sources).
787787
```sql
788788
SET datafusion.optimizer.enable_unions_to_filter = true;
789789
```
790+
791+
### The `RegisterFunction` enum has a new `HigherOrder` variant
792+
793+
`RegisterFunction` now has a `HigherOrder(Arc<dyn HigherOrderUDF>)` variant
794+
so user-defined higher-order functions can be registered
795+
796+
**Who is affected:**
797+
798+
- Users who match on a `RegisterFunction` without a default branch `_ => {}`
799+
800+
**Migration guide:**
801+
802+
Add the new branch to the match with the logic applicable to the context.
803+
804+
```diff
805+
match register_function {
806+
RegisterFunction::Scalar(scalar) => {},
807+
RegisterFunction::Aggregate(aggregate) => {},
808+
RegisterFunction::Window(window) => {},
809+
+ RegisterFunction::HigherOrder(higher_order) => {},
810+
RegisterFunction::Table(name, table) => {},
811+
}
812+
```

0 commit comments

Comments
 (0)