@SuricrasiaOnline okay can anyone tell me about the single most useful macro in praat? Because I can't find anything on that
@schratze @SuricrasiaOnline containment breach happened here: https://cybre.space/@SuricrasiaOnline/106037754746783645
@schratze @SuricrasiaOnline So, people have been doing things like this in C for as long as C has existed -- the very first example I know of is Steve Bourne's macros to make C look more like Algol [ https://research.swtch.com/shmacro ] -- and people have been arguing about whether it's good or bad style for just as long.
At heart, it's an argument about readability, and specifically about when it's okay to make up your own jargon.
@schratze @SuricrasiaOnline The people who like to write code like this think that project-specific jargon is a Good Thing because it makes it easier for the day-to-day maintainers of the code to read it.
You get used to seeing things like https://github.com/praat/praat/blob/9ada48d9055949e4e61d6d94b8513e8c969ab229/melder/MelderFile.cpp#L29 (first example I found of how these macros are _used_). It becomes quicker to read than the alternative with the macros all expanded. Code that _doesn't_ use the macros stands out as doing something special, demands more attention.
@schratze @SuricrasiaOnline On the other hand, the people who dislike code like this think project-specific jargon is a Bad Thing because it makes it harder for _new contributors_ to the code to read it.
Without these macros, anyone reasonably fluent in C would be able to jump in and make changes to the code, but with the macros, they first have to go find where the macros are defined and learn their meaning and their conventional usage. It's an extra obstacle if you just wanna fix one bug.
You'll see people say that they prefer C++ to C because you can hide complicated processing behind simple notation, and you'll see people say that they prefer C to C++ because they don't want that to be possible, they always want it to be visible in the surface syntax when complicated things are happening.
Mastodon is a server for a federated social network: everyone can run a server if they want to, including me. So this is a Mastodon server for me (Vierkantor) and my friends.