Skip to content

6g issue with uint64 variables in conditionals #1032

@gopherbot

Description

@gopherbot

by joerg.sonnenberger:

What steps will reproduce the problem?
1. Add the following to a C source in src/pkg/runtime and try gomake with GOARCH=amd64:

void
foo(uint64 *l)
{
    if (*l)
       *l = 0;
}

What is the expected output?

It should silently compile.

What do you see instead?

> warning: src:line result of operation is not used

with line pointing to the if. This works correctly l is uint32 *.

What is your $GOOS?  $GOARCH?

GOOS=netbsd, GOARCH=amd64

Which revision are you using?  (hg identify)

ca3b155f1eaa

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions