*((char *)NULL) = '\0'; on Nostr: I've seen way too many projects in C that abuse globals so heavily, and I'll never ...
I've seen way too many projects in C that abuse globals so heavily, and I'll never understand it...
I mean, sure they seem handy when you start a small project, but they ALWAYS get out of hand and messy quick.
I tend to define a structure for my globals. Not a perfect solution, but far less messy at least.
Published at
2024-08-30 14:18:16Event JSON
{
"id": "9c8d887a8cbe31790e677dcf6656c8e867e3e2ac38c5c1cee031cbafaceab043",
"pubkey": "86a291ad6bfa9f3d86d212aef6c993cbf52875ca0225e3a8078b822bfa00d848",
"created_at": 1725027496,
"kind": 1,
"tags": [
[
"e",
"5cf9c4cf9f729a433ef6e24ffb3b6ef106508913baadbafec950b9987b363730",
"",
"root",
"04f8915424c713657ad6ce59443d28dbdcf5832687c9af560ae388f59276a137"
],
[
"proxy",
"https://birb.site/@minego/113051401978642794",
"web"
],
[
"p",
"04f8915424c713657ad6ce59443d28dbdcf5832687c9af560ae388f59276a137"
],
[
"proxy",
"https://birb.site/users/minego/statuses/113051401978642794",
"activitypub"
],
[
"L",
"pink.momostr"
],
[
"l",
"pink.momostr.activitypub:https://birb.site/users/minego/statuses/113051401978642794",
"pink.momostr"
],
[
"-"
]
],
"content": "I've seen way too many projects in C that abuse globals so heavily, and I'll never understand it...\n\nI mean, sure they seem handy when you start a small project, but they ALWAYS get out of hand and messy quick.\n\nI tend to define a structure for my globals. Not a perfect solution, but far less messy at least.",
"sig": "808a121181244f0e37c1821df136cdccbecc58b7974d971750bfa612c531179d283db82a2d8ed7d12d4f82942c964320214f03962c693d8ecbe57a4e84cafe86"
}