Closed Kijewski closed 2 weeks ago
That makes me think that we should add a way to bench performance impact somehow (not memory, too unlikely to be useful).
Is it possible to (repeatedly) call rinja_generator::derive_template()
in "normal" code? If so, then I guess benchmarking would be easy. Otherwise, I guess it would be mostly a benchmark for your harddisk and the filesystem cache. :/
I thought we could use something like we have here. We can do an include_str!
and then call the parser on it in the bench I think?
I opened #12 and #13 so it's not forgotten. I think it's really minor improvements so not a priority at all, but could still be interesting. :)
No need to allocate a String, just to write it into another String afterwards. This PR replaces the usages for
format!()
withformat_args!()
.