Re: Idiomatic tokenizing and performance

2014-05-04 Thread Andrew Chambers
Thanks, I should have done that tbh. my code is on github https://github.com/andrewchambers/ccc/blob/master/src/ccc/lex.clj . Don't think it compiles or runs on master currently though. If anyone is interested im trying to test the feasibility/size/maintainability of a clojure (or clojurescript)

Re: Idiomatic tokenizing and performance

2014-05-04 Thread Atamert Ölçgen
I created a gist of your code for better readability, I hope you don't mind. https://gist.github.com/muhuk/7c4a2b8db63886e2a9cd On Mon, May 5, 2014 at 12:36 PM, Andrew Chambers wrote: > I've been trying to make a tokenizer/lexer for a project of mine and came > up with the following code, > I'v

Idiomatic tokenizing and performance

2014-05-04 Thread Andrew Chambers
I've been trying to make a tokenizer/lexer for a project of mine and came up with the following code, I've modelled the stream of characters as seq/lazy of chars which is then converted to a lazy-seq of token objects. I'm relatively happy with how idiomatic and functional the code seems, however