apache / datafusion

Apache DataFusion SQL Query Engine
https://datafusion.apache.org/
Apache License 2.0
6.33k stars 1.2k forks source link

refactor: use `std::slice::from_ref` to remove some clones #13518

Closed jonahgao closed 4 hours ago

jonahgao commented 14 hours ago

Which issue does this PR close?

N/A

Rationale for this change

Replace &[T.clone()] with std::slice::from_ref(&T) to avoid cloning of T.

What changes are included in this PR?

Are these changes tested?

Yes. By existing tests.

Are there any user-facing changes?

No

jonahgao commented 4 hours ago

Thanks @comphead @alamb for the review.