Hacker News new | ask | show | jobs
by pjmlp 28 days ago
I instead, use VC++ latest with C++23 import std.

As for the size requirements, and having Windows experience all the way back to Windows 3.0, you can do exactly the same tricks with C++.

1 comments

Have you checked what dll dependencies you get if you build such an app? And have you actually tried running such an executable on win9x?
If you use only Win32 APIs from C++ just like since Petzold books, the dlls are already there, there is also static linking for other stuff.

Win 9x is a dead OS, why would I bother with that outside retro computing?

Understood, yes, but I described my reasons in my reply to another comment already. Your proposed solution is not equivalent to what I am doing, it cannot work on all the systems I support, and would never be as dependency free.
I fail to see why, as I have been doing C++ on Windows since Windows 3.0.

I only don't consider legacy Windows platforms something to care about, and put the required effort into making something like that happen.

Even trivial stuff causes the linking to vcruntime, this is an extra dll dependency that I don't tolerate, no msvcrt, no vcruntime, nothing except core Win32 dlls are allowed on the platform. Static linking can relieve some of this pain, but that bloats the binary. C++ simply does not allow the same level of minimalism that can be achieved by C, and for many these are unimportant details, for me they are deal breakers and this is a core pillar of my architecture.
First of all VC++ isn't the only C++ compiler on Windows, as it isn't like UNIX with the one true compiler original approach, secondly there are ways with the compiler and linker flags.

I have been avoiding C as much as possible since 1992, starting with Turbo C++ for MS-DOS.

Anyway, to each its own, all the best.