3 ms·
With Nimrod's macro, you can do awesome things. It can improve readability a good deal. Here's an example I made: https://github.com/TechEmpower/FrameworkB
by idlewan 13y ago
With Nimrod's macro, you can do awesome things.
It can improve readability a good deal. Here's an example I made:
https://github.com/TechEmpower/FrameworkBenchmarks/blob/master/nawak/nawak_app.nim#L44 https://github.com/TechEmpower/FrameworkBenchmarks/blob/mast...
Go version:
https://github.com/TechEmpower/FrameworkBenchmarks/blob/master/go/src/hello/hello.go#L92 https://github.com/TechEmpower/FrameworkBenchmarks/blob/mast...
- skybrian 13y agoThe Nimrod version is shorter, but it seems harder to tell whether error-checking is done right.
- idlewan 13y agoNimrod has exceptions. I am catching them (https://github.com/idlewan/nawak/blob/specialpages/nawak_mongrel.nim#L58 https://github.com/idlewan/nawak/blob/specialpages/nawak_mon...) and returning a 500 error page with the detailed exception message. So you need less explicit error-checking everywhere with a language that support exceptions.