Hacker News new | ask | show | jobs
by jeffrallen 2925 days ago
Memory allocation.

Use defer to make code readable. Go code should be readable, so you can figure out if it is correct, and only then should it be fast.

When benchmarking/profiling leads you to a hot spot in the code, rewrite it to remove defers.