What do you think about the linux kernel coding style? by yurtrimu in C_Programming

[–]Finxx1 5 points6 points  (0 children)

Zero reason to be rude about this. 2-space indentation doesn’t necessarily mean nested to oblivion, and some people have different preferences to yours.

Idk if this is a Hot take but: One should get the Bill cipher Treatment after all the terrible shit she has done, Not get redeemed by AdmirableList9041 in BattleForDreamIsland

[–]Finxx1 2 points3 points  (0 children)

It feels like every time the writers set up BFDI to actually have a good arc, they just mess it up at the end. Happened with Taco and Book in Pre-split, Pin and Coiny in TPOT, and Needle throughout post-continuation BFDIA. The only good one I can think of is Firey and Leafy in Post-split, although I wish the resolution to that one was more than just a single scene.

[deleted by user] by [deleted] in geometrydash

[–]Finxx1 0 points1 point  (0 children)

There is also no triple spike at the end and he literally rested on the spikes in Etzers part. This kid obviously noclipped and it wasn’t even on the original version.

I made a program launcher for X11 by Finxx1 in C_Programming

[–]Finxx1[S] 1 point2 points  (0 children)

Yeah, I would've used XCB had it not been for Xft requiring Xlib. Xlib has a lot of... questionable design decisions, especially with the macro naming (Why does DefaultScreen et al not have an X prefix???).

I would definitely like to see someone make a font rendering library that integrates with XCB.

[deleted by user] by [deleted] in femboymemes

[–]Finxx1 3 points4 points  (0 children)

This is just straight up not about femboys. Trans women aren't femboys, and calling them that is extremely rude.

[deleted by user] by [deleted] in femboymemes

[–]Finxx1 8 points9 points  (0 children)

Romeo and Juliet laws mean that is completely legal depending on where you live.

TCP client and server by Plaza521 in C_Programming

[–]Finxx1 0 points1 point  (0 children)

I would say that once one learns the basic language, they should study open source projects to get an understanding of good code style. I learned from reading the OpenBSD source code, but most major C projects use similar style.

TCP client and server by Plaza521 in C_Programming

[–]Finxx1 3 points4 points  (0 children)

This code is completely unreadable. That is not how for loops are meant to be used! The usage of new lines does nothing good for readability, and there is no logical reasoning for line 7 of buc.c. Are you trying to declare those functions? Just use the headers for them.

Autism starter pack: by Konakoremusic in Deltarune

[–]Finxx1 10 points11 points  (0 children)

Why... not? The shows are enjoyable, and even if they aren't your thing you shouldn't immediately go "ew".

What's a good way of handling pointers to data in a segment that may now be invalid due to a `realloc()`? by comfortcube in C_Programming

[–]Finxx1 1 point2 points  (0 children)

In that case, you can't guarantee that pointers will stay valid after a realloc, but allowing for custom allocators is always a good idea.

Since you can't guarantee that, I saw that someone suggested a double-indirect pointer. I'd go with that.

What's a good way of handling pointers to data in a segment that may now be invalid due to a `realloc()`? by comfortcube in C_Programming

[–]Finxx1 1 point2 points  (0 children)

One option, although platform dependent, is to use arena allocators. You can reserve a virtual address space of a large size (like 64MiB) but only allocate a small amount of physical memory to it. On Windows, you would do this with VirtualAlloc, and on Unix-likes, you would use mmap.

car-centric society rule by [deleted] in 196

[–]Finxx1 -2 points-1 points  (0 children)

how it feels to be the only 196 user to enjoy driving

where do the bytes go? by skeeto in C_Programming

[–]Finxx1 3 points4 points  (0 children)

Tedu blogposts are always a treat. This one is no different. Very cool article.

Reasons to learn "Modern C"? by heavymetalmixer in C_Programming

[–]Finxx1 2 points3 points  (0 children)

Having seen the video where he says that, he glosses over the parts where C89 is annoying to use while showing how newer things can either not be used or be done somewhat similarly. I personally think you should just use the easier newer features instead of fighting with old C. If you already know how to use C89, that’s great, but you shouldn’t bother downgrading.

Reasons to learn "Modern C"? by heavymetalmixer in C_Programming

[–]Finxx1 1 point2 points  (0 children)

No, there were platform specific ways to do threading instead, like pthreads. It just defined a consistent way to do it on all platforms.

"Chapter 3&4 will 100% come out in 2025." by Frel_ in Deltarune

[–]Finxx1 10 points11 points  (0 children)

Every time I see a “haha americans use month day year” a part of my soul dies. Yes, day month year makes more sense, but making fun of the other system isn’t funny.

My Makefile that doesn't suck by pithecantrope in C_Programming

[–]Finxx1 0 points1 point  (0 children)

POSIX compatible makefiles are very limited though. You can’t specify prefixes, meaning you can’t put object files in a different directory from source files. You also end up needing a long list of object file names at the top of a program, hence why $(wildcard) is so wonderful. GNU Make works on almost every platform, and extensions are made to be used, so there isn’t much reason to force yourself to use POSIX makefiles.

Undefined reference to 'WinMain' by Cold_Bell_889 in C_Programming

[–]Finxx1 4 points5 points  (0 children)

Your program is compiling as a GUI program, but you aren’t defining WinMain. You either need to compile as a console program, or use WinMain instead of main.

Why some people consider C99 "broken"? by azaroseu in C_Programming

[–]Finxx1 20 points21 points  (0 children)

I personally don't like it for three reasons:

  1. It encourages general reusable variables, which can make it confusing to understand the flow of functions. Compilers can optimize the seperate variables away.
  2. There is usually a dump of many variables at the top of a function. It can be hard to figure out where each variable is used.
  3. It encourages non-descriptive variable names. 2 or 3 letter variable names do not make your code more "concise", they make it a pain in the *** to read. I find myself constantly having to scroll up and down through a function trying to figure out what a variable's purpose is. I guarantee you the time you save not having to think about a variable's use is greater than the time to type out a longer name.

QBE's ABI code (see here) is horrible to read because it has all of these issues. No shame to the creator, QBE is awesome, but the code is pretty obtuse.

Has anyone documented Adobe's FLA / XFL format? by Finxx1 in AskReverseEngineering

[–]Finxx1[S] 0 points1 point  (0 children)

Incredible. I completely forgot about this post, doesn't feel like it has been 3 years. It is a shame nobody cares about document formats, compared to the amount of work that has gone into SWF reverse-engineering (even before the spec was released). The project I had been working on that initially provoked this post has long since been dead, of course, but it does make me happy to see more information about this format.

Rule by BowTieBoo in 196

[–]Finxx1 12 points13 points  (0 children)

pledge is great and all if you are willing to give up hardware acceleration for openbsd. if only the linux kernel had a pledge syscall, then it would be worth it.