Why the FUCK does CMAKE generate VS project files that depend on having CMAKE installed on your system? And it has to be in a fixed path? And EVERYTHING has to be in a fixed path?
Have CMAKE developers ever compiled something or used version control? This is unusable and I am very angry and it's Monday and I haven't had my coffee yet.
EDIT: AND IT HAS TO HAVE VS INSTALLED AT A FIXED PATH TOO WHO MADE THIS CRAP????
Out of 6 languages recommended by the NSA, 4 are patended bvy multibillion comanies who can pull the plug on them at any time (and Oracle already tried that).
C# - PATENTED by Microsoft,
Go - PATENTED by Google
Java - PATENTED by Oracle, NOT FREE
Python - not too shabby
Rust - not too shabby
Swift - PATENTED by Apple
I’ve been having a bit of a play around with my Agon Light, trying to come up with some ideas for a future video. I’ve discovered it has quite a nice 320×240 64 colour video mode that has just enough pixels to be interesting.
Here’s a little thing I managed to create.
TIt started off as a little discussion with ChatGPT and ended with a Python and PyGame program that drew one spinning shape in the middle of the screen. I’m finding ChatGPT is quite good for coming up with code that I would have otherwise spent hours trying to figure out.
The code isn’t the most efficient, I’m using floating point maths all over the place – on a device with an eZ80 CPU that doesn’t have an FPU. Writing this to use fixed point maths is an exercise for future me.
I am talking about McPixel 3 Engine that I wrote from scratch in C.
It has been ported to Windows, Max, Linux, Switch, Xbox One, Xbox Series, PS4, PS5, iOS, Android, Windows 95, Raspberry Pi, FreeBSD, Haiku OS, RISC-V, Windows 3.51, MS-DOS and Linux Terminal.
Another bit of gold from #ICFP2023 by Pjotr Prins of the University of Tennessee. The actual title of the talk is "Why code in Python+C if you can code in Lisp+Zig?" but the "Lisp" in this case is actually Guile Scheme. I didn't know this, but Zig uses the C ABI so it binds to any language that can do FFI bindings to C, including most Scheme and Common Lisp implementations. But why don't I just post the abstract here:
> "Most bioinformatics software today is written in Python and for performance C is used. Lisp has been around for over half a century and here I don’t have to tell how or why programming Lisp is great. I will talk about Zig as a minimalistic new language that is unapologetically focused on performance, tellingly with a blazingly fast compiler. It is advertised as a replacement for Thompson, Ritchie, and Kernighan’s C, but it may even replace C++ in places. Zig uses the C-ABI and does not do garbage collection, so it is ideal for binding against other languages. In this talk I will present combining GNU Guile Lisp with Zig. I’ll argue that everyone needs two languages: one for quick coding and one for performance. With Guile and Zig you get both at the same time and you won’t have to fight the Rust borrow checker either."
#c#clang
If your #C library function doesn't mutate memory passed to it but wants to return modifiable pointers, do you const the parameter but cast-away the const on return?
Or do you not const the parameter at all?
It's 2023 and there are still buildsystems, which do not warn about a empty list of source files as input.
If my glob does not match anything, I probably want a warning and not an empty shared library as output. #workwork#cprogramming
I think I can do it. I think I can get through my entire professional software development career without ever learning C++ beyond the basics. I’ve done more than my fair share of C, Java, Ruby, Rust, Go, Python, JavaScript, and even Perl, but somehow I’ve escaped C++ except for one TINY work project that I somehow didn’t fuck up too badly.
@tilton you need to know that modern (post-2015) C++ is not like C. While much of C syntax is still accepted, don't write C in C++ unless you're interfacing with legacy code. In particular, avoid managing memory yourself, use containers and local variables instead.
On that note: C is not a "portable assembler", think of it as running on a VM that's just really good at generating code—the VM behavior (or "abstract machine") may or may not match your hardware. #cPlusPlus#cLanguage#cProgramming
I am learning #c and I am pretty much a beginner both with that language and in programming in general. I am looking for a mentor to help me to make sure I am on the right track and help me avoid bad habits as much as possible. I really want to learn C and I need the help and motovation to evolve. One of the reasons why is because I want to try to become a Linux kernel developer on the C part of it. So is there anyone with relatively good grasp around C and who can help me and be my mentor?