bruxisma / byteswap

WG21 P1272 -- Byteswap Implementation

Home Page:https://wg21.link/p1272

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Overview

This is a draft proposal for adding a std::byteswap function to the C++ standard library. This repository features the proposal and a working C++17 implementation for GCC/Clang/MSVC. On all platforms, it will insert a bswap instruction via a compiler intrinsic if called in a non-constexpr context, and will perform a constexpr byteswap otherwise.

The proposal is still in draft mode and will be updated with proper wording over time.

This implementation is released under an MIT License.

About

WG21 P1272 -- Byteswap Implementation

https://wg21.link/p1272

License:MIT License


Languages

Language:C++ 100.0%