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

At comptime, a slice of a slice of an array is treated as const. #826

tgschultz opened this Issue Mar 11, 2018 · 0 comments


None yet
2 participants

tgschultz commented Mar 11, 2018

test "test" {
    comptime {
        var buff: [10]u8 = undefined;
        ((buff[0..])[0..])[0] = 1;
error: cannot assign to constant
        ((buff[0..])[0..])[0] = 1;

@andrewrk andrewrk added the bug label Mar 11, 2018

@andrewrk andrewrk added this to the 0.2.0 milestone Mar 11, 2018

@andrewrk andrewrk closed this in 1bf2810 Mar 12, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment