C++

Error codes vs exceptions

Në shqip: Kodet e gabimit apo përjashtimet

ShpjegimiSQ

Në C++ gabimet trajtohen në dy mënyra: me përjashtime (throw/catch) ose duke kthyer kode gabimi (std::error_code, std::expected). Lojërat dhe sistemet e integruara shpesh i fikin përjashtimet për shpejtësi.

EnglishEN

In C++ errors are handled two ways: with exceptions (throw/catch) or by returning error codes (std::error_code, std::expected). Games and embedded systems often switch exceptions off for speed.

Si ta mendosh

Si dy mënyra për të njoftuar një problem: alarmi që bie (përjashtim) ose shënimi në raport (kod gabimi).

Lexoje në anglisht

Like two ways to report a problem: a ringing alarm (exception) or a note in the report (error code).

Terma të lidhur