Canonical guidance

Use when

Avoid

Preferred pattern

timeout := time.Duration(ms) * time.Millisecond

Anti-pattern

Explanation: This is tempting because the syntax is short, but ordinary conversions follow language rules, not zero-copy performance wishes.

Why

Related pages

Sources