AI-powered
podcast player
Listen to all your favourite podcasts with AI-powered features
The Right Way to Write Simple Variable Code
In go programs no functions they can return any number of return values right. This is not something that most languages are doing and so when you look at the assembly language then it turns out to be translated in CPU code in very different ways than you know normal functions are supposed to work right. When you have a function that can only return single arguments which is the case for a lot of languages out there like CC++ etc then you have a very simple convention. The convention says oh the return value will be in register EX in assembly this is like this is the rule. It's very simple when it comes to go language then you know you don't have a single place because you can have several