Skip to content

Wrong type accessibility error is not reported for a signature #11331

@auduchinok

Description

@auduchinok

B..ctor signature should report an error about a use of an internal type in a public member:

module WrongAccessibility.Library

type internal A = class end

type B =
    new: a: A -> B

A library containing such a signature is successfully built, and there's a runtime exception when trying to use the constructor of B.

The bug leads to exception when trying to use ILFieldDef:

new: name: string * fieldType: ILType * attributes: FieldAttributes * data: byte[] option *

Metadata

Metadata

Assignees

Labels

AI-thinks-issue-fixedArea-Compiler-CheckingType checking, attributes and all aspects of logic checkingArea-Compiler-Checking-AccessibilityVisibility checks: internal, private, protected, InternalsVisibleToBugImpact-Medium(Internal MS Team use only) Describes an issue with moderate impact on existing code.

Type

No fields configured for Bug.

Projects

Status

New

Relationships

None yet

Development

No branches or pull requests

Issue actions