Skip to content

Compiler segfauts when shifting by a vector with an undefined value #24392

@Validark

Description

@Validark

Zig Version

0.15.0-dev.936+fc2c1883b

Steps to Reproduce and Observed Behavior

https://zig.godbo.lt/z/5xhenbabn

export fn foobar(x: @Vector(16, u8)) @Vector(16, u8) {
    return x >> @as(@Vector(16, u3), 
        .{ 0, 1, 2, 3, 4, 5, 6, 0, 0,  1,  2,  3,  4,  5,  6, undefined }
    );
}

It segfaults

Expected Behavior

I expect no segfault

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugObserved behavior contradicts documented or intended behavior

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions