MrJayLC Profile Banner
John Profile
John

@MrJayLC

Followers
161
Following
7K
Media
1K
Statuses
11K

CEO #htmx Foundation Putting C back in CDeezNutz Inc. Master of CompSci Hobby 3D Animator Competitive shooter Occasional DnDer Wool is king, thanks Grandma

Norway
Joined March 2011
Don't wanna be here? Send us removal request.
@MrJayLC
John
2 years
@IroncladDev Unless the preference is unaligned indentation, anyone who prefers aligned indentation either prefers 1 space indentation or tabs. The rest are posers.
1
0
4
@MrJayLC
John
3 days
But C strings are superior when parsing, because you only have to check for the sentinel, which is part of the jump table of things you're checking for. The real problem is that you cannot have a non-sentinel string by literal. Pstrings, SVs, SBs. Most don't need a sentinel.
@neogoose_btw
Dmitriy Kovalenko
4 days
One of the biggest problems of C are strings. Better to say no out of the box strings. *const u8 is absolutely the worst way to represent strings because every time you need to compare the strings you have to loop over the bytes instead of starting with length comparison
0
0
1
@MrJayLC
John
20 days
poor man's lambda achieved, however there is a byproduct of mprotect affecting entire pages that makes each lambda require an entire page of their own whilst also rendering any data portion read-only, which is annoying. Makes for a storage question of a lambda as FAM.
0
0
0
@MrJayLC
John
20 days
I can name at least two types in machine code: register width and flag.
@rfleury
Ryan Fleury
21 days
Everyone saying “but there are no types in machine code!” didn’t understand the point. You may want to look at how a JavaScript object is actually implemented. Static types become necessary—even if conceptual, just within assembly—because different runs of machine code need to
0
0
1
@MrJayLC
John
22 days
Nothing is stopping libc from being updated to track resource acquisition and relinquish as part of the CRT. the CRT has an init and a fini step, of which it could set up resource locations to track pages and files allocated, and just release them on exit. It just doesn't.
@Adriksh
Adriksh
23 days
C is hard because you have to manually free every pointer. Actually, you don't. 🤫 The cleanup attribute allows you to define a function that runs automatically when a variable goes out of scope. It's basically RAII/Destructors in C.
0
0
0
@MrJayLC
John
25 days
Highly functioning adult over the age of 30 btw. (My OOPness is very smol).
@tsoding
Тsфdiиg
26 days
Java is a language with a huge OOPness
0
0
0
@MrJayLC
John
26 days
This is what I like to call "C++ Template Type Explosion". Eventually, you end up wrapping it all up in a using somewhere and just shove it under the rug. Image from @lefticus, https://t.co/IITymVDjml
0
0
0
@MrJayLC
John
26 days
based gamedev: "For less taxes, get married!" soy devs (like me):
0
0
0
@MrJayLC
John
27 days
Hipp hipp and hooray, happy new year :^)
0
0
0
@MrJayLC
John
27 days
Function pointers need a buff with attributes. @__phantomderp wdyt?
1
0
1
@MrJayLC
John
28 days
Wish my units were huge. Translation Units, of course.
@pikuma
pikuma.com
28 days
My binaries are average size. I cheched.
0
0
1
@MrJayLC
John
28 days
Why do I feel like I'm refollowing people I've already followed before? Strange.
0
0
0
@MrJayLC
John
28 days
paracetamol != ibuprofen afaik anti-inflammatory is what you want to offer the whamen for their period pains. Gotta give a *little* effort.
0
0
0
@MrJayLC
John
28 days
Thinking about the SYS-V Initial Process Stack: The Auxiliary Vector contains configurations of the system (such as system-name and page size). Why on earth is it lower than ArgC, ArgV and EnvP? Makes you waste time iterating over EnvP just to get to AuxV, which makes me :(
0
0
0
@MrJayLC
John
28 days
+1 recommended, video:
@valigo
Valentin Ignatev
29 days
You can just do things???
0
0
1
@MrJayLC
John
30 days
Bastardizing nob.h with function pointers @tsoding Also, nice "cancer" logging!
1
0
0
@MrJayLC
John
1 month
Is there any reason why printf can't have a function pointer that operates on an arg by (void) pointer and returns a string? printf("%U\n", &struct_printer, &struct_var);
0
0
0
@MrJayLC
John
1 month
Ah yes, because having an iPhone USB-C that refuses to charge non-iPhone devices is such an improvement! Not to mention specs on voltage, amp, frequencies, etc. might all differ. Go tardwrangling! Always use power cable and converters to the devices they're made for.
@TimSweeneyEpic
Tim Sweeney
1 month
This was a great move by Europe and much needed standardization that has made hardware better everywhere. So much better than companies who formerly profited from incompatible cables, once forced to adopt USB-C, touted it in their marketing.
0
0
0
@thestanduppod
TheStandupPod
1 month
Casey Tries Node
86
231
3K
@MrJayLC
John
1 month
Merry Twitter-mas (hehe). We will C 2026 soon!
0
0
0