Codechange: Replace old non-standard attributes with C++17/20 standard attributes.
This commit is contained in:
@@ -17,7 +17,7 @@
|
||||
* Function to exit with an error message after malloc() or calloc() have failed
|
||||
* @param size number of bytes we tried to allocate
|
||||
*/
|
||||
void NORETURN MallocError(size_t size)
|
||||
[[noreturn]] void MallocError(size_t size)
|
||||
{
|
||||
FatalError("Out of memory. Cannot allocate {} bytes", size);
|
||||
}
|
||||
@@ -26,7 +26,7 @@ void NORETURN MallocError(size_t size)
|
||||
* Function to exit with an error message after realloc() have failed
|
||||
* @param size number of bytes we tried to allocate
|
||||
*/
|
||||
void NORETURN ReallocError(size_t size)
|
||||
[[noreturn]] void ReallocError(size_t size)
|
||||
{
|
||||
FatalError("Out of memory. Cannot reallocate {} bytes", size);
|
||||
}
|
||||
|
Reference in New Issue
Block a user