mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 07:37:46 +00:00
AK: Mark the error branch of the TRY() macro as unlikely
This results in a measurable (and free!) 2% improvement in test-js run time.
This commit is contained in:
parent
309d71a66b
commit
8a879e205b
1 changed files with 6 additions and 6 deletions
2
AK/Try.h
2
AK/Try.h
|
@ -12,7 +12,7 @@
|
||||||
#define TRY(expression) \
|
#define TRY(expression) \
|
||||||
({ \
|
({ \
|
||||||
auto _temporary_result = (expression); \
|
auto _temporary_result = (expression); \
|
||||||
if (_temporary_result.is_error()) \
|
if (_temporary_result.is_error()) [[unlikely]] \
|
||||||
return _temporary_result.release_error(); \
|
return _temporary_result.release_error(); \
|
||||||
_temporary_result.release_value(); \
|
_temporary_result.release_value(); \
|
||||||
})
|
})
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue