|
|
|
RFC Should functions have a color?
|
|
2 points
by Merkur
3866 days ago
|
|
The title is a reference to http://journal.stuffwithstuff.com/2015/02/01/
what-color-is-your-function/ a joyfull rant about async functions and promises. I like to request your comment on a similar topic. While coding in go - I often find me asking: is this package go-routine save? Many times I find the answer in the doc's or can ask on the internet, sometimes I need to look at the code. "go routine safety" is just like the color in the rant of munificent. On a current project I would like to assert that a user provided callback is a pure function - there we got another color! those two colors are alike - they represent meta informations about an entity (function, package, struct) and they are about the behavior of the entity. They also have something to do with boundarys - tho my English skills deny me to elaborate :( I wounder... Do you know other kinds of colors? Is that coloring bothering you? And if not how do you approach it? |
|