Zig 0.17.0-dev (Split by item)

Shortcut keys
?
Show these tips
S
Focus search field
Esc
Clear focus & close tips
U
Jump to source code
↑
Move up in search results
↓
Move down in search results
↵
Go to active search result
This is an example of documentation generated by ZigDoc, an alternative to Zig's built-in Auto Doc feature. See also examples in other modes/formats. The project being documented here (as the example) is the Zig standard library. Public Struct

Float128

Public Struct
std.zig.Zir.Inst.Float128
pub const Float128 = struct

A f128 value, broken up into 4 u32 parts.

Fields

piece0: u32
piece1: u32
piece2: u32
piece3: u32

Functions

pub fn get(self: Float128) f128

File

zig/Zir.zig:3794
3794
3795
3796
3797
3798
3799
3800
3801
3802
3803
3804
3805
3806
3807
    pub const Float128 = struct {
        piece0: u32,
        piece1: u32,
        piece2: u32,
        piece3: u32,

        pub fn get(self: Float128) f128 {
            const int_bits = @as(u128, self.piece0) |
                (@as(u128, self.piece1) << 32) |
                (@as(u128, self.piece2) << 64) |
                (@as(u128, self.piece3) << 96);
            return @as(f128, @bitCast(int_bits));
        }
    }