1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 18:57:35 +00:00

AK: Always inline convert_between_host_and_network<T>.

This commit is contained in:
Andreas Kling 2019-05-21 16:14:02 +02:00
parent e383bc6fd8
commit a8313ae0a3

View file

@ -3,7 +3,7 @@
#include <AK/Types.h> #include <AK/Types.h>
template<typename T> template<typename T>
T convert_between_host_and_network(T host_value) [[gnu::always_inline]] inline T convert_between_host_and_network(T host_value)
{ {
if constexpr (sizeof(T) == 4) { if constexpr (sizeof(T) == 4) {
auto* s = (byte*)&host_value; auto* s = (byte*)&host_value;