Go Closure

What are closures? From Wikipedia A closure is a data structure storing a function together with an environment, a mapping associating each free variable of the function (variables that are used locally, but defined in an enclosing scope) with the value or storage location the name was bound to at the time the closure was created. What does that mean? In simple words, it means that a function can contain (or return) another function which is called closure.

Read On →

Dealing With Import Cycles in Go

Go doesn’t allow import cycles to occur. If there are any import cycles detected, it throws a compile time error. Generally import cycles are considered as a bad design. I recently came across such a situation when I wrote a test case to test my models, my config package that returned a db connection was dependent on model and the controller created a connection of type gorp.DbMap and passed it to each call in the model.

Read On →

My First Product

Coding is one thing, but making an app all the way from scratch and selling it is another. I am a backend/website dev by profession, staying in B’lore, India. I wanted to explore what goes through in creating a product. I always saw some bad products and some good products around me and wondered why people made those shitty stuff and wondered how they made money with it. I being technical, the way the product works and appears to the end user (design) is priority.

Read On →