Is there a tool/linter to check if a private package function gets called 
exactly once *in the code*? (I'm not looking for a runtime solution like 
*sync.Once* but a code analysis tool/linter).

Purpose: A guideline on commenting code by Martin Fowler states that before 
writing a comment, see if it is possible to put that part inside a 
meaningful function. I've followed that guideline for sometime and it helps 
to have a cleaner code base. But those explanatory functions should get 
called only from where that they are meant to make it more clear.

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to