Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

support int128 uint128 with gcc or clang #342

Merged
merged 7 commits into from
Jul 6, 2023
Merged

Conversation

982945902
Copy link
Contributor

Why

complete potion TODO

What is changing

support int128 uint128 with gcc or clang

Example

TEST_CASE("int128/uint128") {
using int128_t = __int128;
using uint128_t = signed __int128;

{
int128_t it = -2131231231213123;

auto ts = struct_pack::serialize(it);

auto it_ = struct_pack::deserialize<int128_t>(ts);

CHECK(it == it_);
}

{
uint128_t it = 2131231231213123;

auto ts = struct_pack::serialize(it);

auto it_ = struct_pack::deserialize<uint128_t>(ts);

CHECK(it == it_);
}

}

@CLAassistant
Copy link

CLAassistant commented Jun 29, 2023

CLA assistant check
All committers have signed the CLA.

@poor-circle
Copy link
Collaborator

Thanks you!

@poor-circle
Copy link
Collaborator

I will add document & testcase later.

@poor-circle poor-circle merged commit 15ed609 into alibaba:main Jul 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants