Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: remove lexical (replace with atoi_simd, ryu, and itao). #12512

Merged
merged 2 commits into from
Nov 16, 2023
Merged

Conversation

ritchie46
Copy link
Member

@ritchie46 ritchie46 commented Nov 16, 2023

Still have some lexical in arrow cast. Will get that out later.

closes #12463

@ritchie46 ritchie46 requested a review from orlp as a code owner November 16, 2023 11:04
@github-actions github-actions bot added enhancement New feature or an improvement of an existing feature python Related to Python Polars rust Related to Rust Polars labels Nov 16, 2023
@@ -570,42 +570,19 @@ pub fn cast(
},

(Utf8, _) => match to_type {
UInt8 => utf8_to_primitive_dyn::<i32, u8>(array, to_type, options),
Copy link
Member Author

Choose a reason for hiding this comment

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

Remove branches we never hit in polars.

_ => polars_bail!(InvalidOperation:
"casting from {from_type:?} to {to_type:?} not supported",
),
},
(LargeUtf8, _) => match to_type {
UInt8 => utf8_to_primitive_dyn::<i64, u8>(array, to_type, options),
Copy link
Member Author

Choose a reason for hiding this comment

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

Reuse the binary code for this.

@ritchie46 ritchie46 changed the title feat: replace (parts) of lexical with atoi_simd feat: remove lexical (replace with atoi_simd, ryu, and itao). Nov 16, 2023
@ritchie46 ritchie46 merged commit 82a7bd5 into main Nov 16, 2023
28 checks passed
@ritchie46 ritchie46 deleted the atoi branch November 16, 2023 12:40
@stinodego stinodego added the build Changes that affect the build system or external dependencies label Nov 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build Changes that affect the build system or external dependencies enhancement New feature or an improvement of an existing feature python Related to Python Polars rust Related to Rust Polars
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Replace lexical crate
2 participants