Re:John Carmack on Inlined Code
by to3m on Friday September 26, 2014 @04:47PM
(#8374765)
This is what I do as well, for exactly the same reasons. (You saved me a post. Thanks!) It works pretty well, I think. As you say, it's nice to have the code just written out in the order in which it will be executed.
It can look a bit daunting at first sight - if you're not used to this style of code, it just looks like your average rambling stream-of-consciousness function - but it's actually pretty easy to keep on top of. And if people really complain, it's super-easy to split out into functions :)
It can look a bit daunting at first sight - if you're not used to this style of code, it just looks like your average rambling stream-of-consciousness function - but it's actually pretty easy to keep on top of. And if people really complain, it's super-easy to split out into functions :)