I've been doing a lot of "differential debugging" on the Lua codebase lately. There's something going off the rails in a part of Teliva that I don't understand yet. I try to make my change in a temporary copy of the unmodified Lua sources and step through to see, what is the control flow supposed to look like? Then I compare with what's happening in Teliva. Where does it go off the rails? Super useful to have working software that is so easy to compile.
I've been programming in C++ for a long time, and just ran into a very surprising situation in C.
$ cat x.c
inline int foo(void) {
return 42;
}
int main(void) {
return foo();
}
$ gcc -c x.c
$ gcc x.o
undefined reference to 'foo'
$ gcc -O1 -c x.c
$ gcc x.o
# no error
If you compile without optimizations, the `inline` keyword does nothing -- but the function is still excluded from the object file.
One of the hidden gems in luapower is this little bash script called multigit. It.. oh heck, I'll just let you read about it and have your mind blown: https://github.com/capr/mgit
Relevant excerpt:
"NO [SUB-]DIRECTORIES
This may be a hard sell but I stand by it. [Sub-]directories are evil. Not so much because of semantics, but because of the tools we use suck at working with them. No global overview; instead you have to navigate them."