Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I don't think the lookup tables is a micro-optimization. They're both clear and fast in this case (I can't think of a more clear alternative, just of a less verbose one). The "switches" are actually pattern matching, a very powerful feature of Rust. I'm not sure about nesting them being a micro-optimization either. I think it's also a choice that is both readable and fast. Can a more experienced Rust code shed light?


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: