Skip to content

No syntax error for primary constructor in delegate definition #8299

@auduchinok

Description

@auduchinok

No error is reported for the following code:

type T(x: int) =
    delegate of int -> int

When sending this code to fsi, an error is produced:

error FS0193: internal error: Illegal definition for runtime implemented delegate method.

Metadata

Metadata

Assignees

Labels

Area-Compiler-CheckingType checking, attributes and all aspects of logic checkingBugImpact-Low(Internal MS Team use only) Describes an issue with limited impact on existing code.good first issue

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions