Skip to content
This repository has been archived by the owner on Feb 18, 2024. It is now read-only.

Commit

Permalink
Added io_csv_read and io_csv_write feature (#408)
Browse files Browse the repository at this point in the history
  • Loading branch information
ritchie46 authored Sep 17, 2021
1 parent 06c45f8 commit d5cc0db
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 4 deletions.
4 changes: 3 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,9 @@ full = [
"chrono-tz",
]
merge_sort = ["itertools"]
io_csv = ["csv", "lazy_static", "regex", "lexical-core", "streaming-iterator"]
io_csv = ["io_csv_read", "io_csv_write"]
io_csv_read = ["csv", "lazy_static", "regex", "lexical-core"]
io_csv_write = ["csv", "streaming-iterator", "lexical-core"]
io_json = ["serde", "serde_json", "indexmap"]
io_ipc = ["flatbuffers"]
io_ipc_compression = ["lz4", "zstd"]
Expand Down
4 changes: 4 additions & 0 deletions src/io/csv/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,5 +16,9 @@ impl From<chrono::ParseError> for ArrowError {
}
}

#[cfg(feature = "io_csv_read")]
#[cfg_attr(docsrs, doc(cfg(feature = "io_csv_read")))]
pub mod read;
#[cfg(feature = "io_csv_write")]
#[cfg_attr(docsrs, doc(cfg(feature = "io_csv_write")))]
pub mod write;
2 changes: 1 addition & 1 deletion src/io/mod.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
//! Interact with different formats such as Arrow, CSV, parquet, etc.
#[cfg(feature = "io_csv")]
#[cfg(any(feature = "io_csv_read", feature = "io_csv_write"))]
#[cfg_attr(docsrs, doc(cfg(feature = "io_csv")))]
pub mod csv;

Expand Down
4 changes: 2 additions & 2 deletions src/util/mod.rs
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
//! Misc utilities used in different places in the crate.
#[cfg(any(feature = "compute", feature = "io_csv"))]
#[cfg(any(feature = "compute", feature = "io_csv_write", feature = "io_csv_read"))]
mod lexical;
#[cfg(any(feature = "compute", feature = "io_csv"))]
#[cfg(any(feature = "compute", feature = "io_csv_write", feature = "io_csv_read"))]
pub use lexical::*;

#[cfg(feature = "benchmarks")]
Expand Down

0 comments on commit d5cc0db

Please sign in to comment.