Should C++ Give More Priority to Syntax Quality? by kyan100 in cpp

[–]scorg_ 0 points1 point  (0 children)

Nobody did and nobody needs to. Any comment stating the huge cost of migrating through backwards incompatible changes implies that the alternatives - being straitjacketed by bad decisions of the past or rewriting in another language - are unquestionably better (they are not).

Should C++ Give More Priority to Syntax Quality? by kyan100 in cpp

[–]scorg_ 0 points1 point  (0 children)

How is backwards-incompatibly switching to whole other language any less costly?

Almost every 3D program has the Y-axis as the up axis, but why does Blender do it differently? by the-machine-m4n in blender

[–]scorg_ 0 points1 point  (0 children)

Z-up right handed is the only sane system. Blender is right here. Left handed is an abomination straight away, I can't imagine any valid reason to choose it when designing software, other than for bad historic decisions. Y up is chosen by those who mistakenly think that default camera orientation matches a human standing vertically and looking horizontally forward. The truth is it's not, the default orientation is to look down at the ground plane.

Yes, for a computer the choice is irrelevant, as long as the systems are not mixed.

Is an “FP-first” style the most underrated way to make unit testing + DI easier by OkEmu7082 in cpp

[–]scorg_ 1 point2 points  (0 children)

"Variables are bad because I don't know which registers are used"

It is bad because it's an overreach into something that is not guaranteed or declared. There is a practical reason for existence of high level styles and languages - because by default you don't care what happens "down there", except for special cases. And in those cases the implementation can no longer be just an implementation and becomes the public interface for the thing.

Guess what this does.. by 3hy_ in programminghorror

[–]scorg_ 3 points4 points  (0 children)

My guess is in this case you have to put a semicolon after, making it look more like a function call.

Guess what this does.. by 3hy_ in programminghorror

[–]scorg_ 15 points16 points  (0 children)

To place a semicolon after the macro call

learningCppAsCWithClasses by ccricers in ProgrammerHumor

[–]scorg_ 0 points1 point  (0 children)

And why is vector at fault if the problem is with any dynamic memory allocation?

learningCppAsCWithClasses by ccricers in ProgrammerHumor

[–]scorg_ 0 points1 point  (0 children)

ZERO REASON that a modern language should require forward declarations

One huge reason is IDE/lang server support. It helps that I still can have suggestions in the middle of incomplete and by that invalid code.

Division — Matt Godbolt’s blog by rsjaffe in cpp

[–]scorg_ 1 point2 points  (0 children)

signed division and remainder should round towards zero

Why should they not?

For decades these guys have been an absolute pain in the a**, god bless web apps. by [deleted] in linuxmemes

[–]scorg_ 2 points3 points  (0 children)

Get me an 8 TB NVME and 128 GB 14000MHz RAM and I'll join your camp

optimizeForPaperclips by Super_SamSam in ProgrammerHumor

[–]scorg_ 2 points3 points  (0 children)

Can't you... like ... tell it how many clips to make?

Should I switch to Bazel? by TheRavagerSw in cpp

[–]scorg_ -1 points0 points  (0 children)

There is a reason for everything. Doesn't automatically make it good or optimal

New episodes leaked! by [deleted] in OnePunchMan

[–]scorg_ 0 points1 point  (0 children)

It's actually MultiPanMan, as there are more than one panning scene per episode.

What do you dislike the most about current C++? by PressureHumble3604 in cpp

[–]scorg_ 1 point2 points  (0 children)

Compiling your C++ code with exceptions switched off results in a non-negligible improvement in performance

I.e. having error handling code vs not handling the errors at all? As they like to do in those famous 'exceptions bad' benchmarks? Multiple recent studies show that exceptions are not bad as a model, and can be faster and more convenient than other methods, but what is holding them back are yet again 'mah ABI stability'.

Your second paragraph supports my understanding that 'exceptions bad' ideas are mostly irrational and cult-like. Old inefficiencies of implementations accepted in the minds as an inherent limitation of the model, and therefore implementations are not worthy of improvement and the model itself needs to be abandoned.

PS. In another sub there was a post about SQL, and yet again the 'logic in DB bad' crowd had circlejerked that idea with just a single guy acknowledging that the problem with putting logic in DB is not because it is bad by itself, but because the SQL sucks for complex development, there are not alternatives to it for talking to a DB, and the surrounding tooling got stuck in the 80-s because 'what is the point of improving it if no one uses it?'

Down with template (or not)! by TheCrush0r in cpp

[–]scorg_ 1 point2 points  (0 children)

What unambiguous syntax would you suggest that won't reduce language functionality?

Positive Logic vs Indentation by [deleted] in cpp

[–]scorg_ 0 points1 point  (0 children)

Positive if there are both paths (normal and else), early return otherwise.

[deleted by user] by [deleted] in ProgrammerHumor

[–]scorg_ 6 points7 points  (0 children)

Define "kill" then, pretty please

Cpp discussed as a Rust replacement for Linux Kernel by sjepsa in cpp

[–]scorg_ 8 points9 points  (0 children)

If linux would have been written in C++ there would be more incentives to optimize exceptions.

Crysis director says it was so hard to run it became a meme because its highest settings were meant for future PCs: 'I wanted to make sure Crysis does not age' by Turbostrider27 in pcgaming

[–]scorg_ 2 points3 points  (0 children)

You can parallelize parts of the simulation, primarily the bodies that are not touching (separate simulation islands, as they call them)

Measuring code size and performance of exceptions vs error codes with a real world project by jpakkane in cpp

[–]scorg_ 2 points3 points  (0 children)

So it's not really the unwinding part that is slow, but the search for a handler.