Skip to content

Unsafe static using errors unexpectedly differ based on declaration order #82426

@jjonescz

Description

@jjonescz

Version Used: 5.5.0-2.26110.7 (47f526d)

Steps to Reproduce:

using static C<int*[]>; // error - expected
using static unsafe C<long*[]>; // error - unexpected
class C<T>;
using static unsafe C<int*[]>; // no error - expected
using static C<long*[]>; // no error - unexpected
class C<T>;

This seems to be because the binder (and hence its unsafe flag) is cached when going through the list of using declarations.

Related to test plan #56323.

Metadata

Metadata

Assignees

Type

No fields configured for Bug.

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions