Jimexist opened a new issue #448:
URL: https://github.com/apache/arrow-datafusion/issues/448


   I wonder if a more idomatic Rust way of doing this would be an enum like
   
   ```rust
   enum NthValue {
     First,
     Last,
     Nth(u32)
   }
   
   ```
   
   And then in `NthValueAccumulator::scan` you would have something like
   
   ```
   match self.n {
     NthValue::First|NthValue::Nth(1)  => {...}
     Nth::Last => {..}
   }
   ```
   
   There is nothing wrong with the special value approach either -- I just 
figured I would point it out
   
   _Originally posted by @alamb in 
https://github.com/apache/arrow-datafusion/pull/403#r640837938_


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to