Skip to content

Commit

Permalink
projection takes slice instead of vec
Browse files Browse the repository at this point in the history
  • Loading branch information
andygrove committed Mar 14, 2019
1 parent 7e1a98f commit c56510e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion rust/arrow/src/datatypes.rs
Original file line number Diff line number Diff line change
Expand Up @@ -754,7 +754,7 @@ impl Schema {
}

/// Create a new schema by applying a projection to this schema's fields
pub fn projection(&self, projection: &Vec<usize>) -> Result<Arc<Schema>> {
pub fn projection(&self, projection: &[usize]) -> Result<Arc<Schema>> {
let mut fields: Vec<Field> = Vec::with_capacity(projection.len());
for i in projection {
if *i < self.fields().len() {
Expand Down

0 comments on commit c56510e

Please sign in to comment.