Skip to content

gccgo: spurious expected newline error #11528

Description

@dvyukov

gcc rejects the following program:

package e
const(G=0/*
*/V)
go.go:3:3: error: expected ‘;’ or ‘)’ or newline

The spec says:

General comments start with the character sequence /* and continue through the character sequence */. A general comment containing one or more newlines acts like a newline, otherwise it acts like a space.

Both gc and go/types accept this program.
gcc version 6.0.0 2015070 (experimental) (GCC)

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions