-
Notifications
You must be signed in to change notification settings - Fork 4.2k
Closed
Labels
Area-CompilersTestTest failures in roslyn-CITest failures in roslyn-CITest-GapDescribes a specific feature or scenario that does not have test coverageDescribes a specific feature or scenario that does not have test coverage
Milestone
Description
Championed issue: dotnet/csharplang#1888
- Specification checked in to
csharplang. - attribute on declaration
- attributes on declaration are emitted
- attribute on return type
- attributes on return type are emitted
- attribute on type parameters
- attributes on type parameters are emitted
- attribute on parameters
- attributes on parameters are emitted
- Correctness of
AttributeUsage- On declaration and return](https://github.com/dotnet/roslyn/blob/features/local-function-attributes/src/Compilers/CSharp/Test/Semantic/Semantics/LocalFunctionTests.cs#L631)
- On parameters and type parameters
- interaction with potentially ambiguous syntax?
- speculative semantic model Speculative semantic model produces different behavior for local functions #24135
- semantic model on attribute arguments for method/return/param/type param attributes
-
expected diagnostics when binding a local function statement in speculative semantic model- Speculative semantic models don't give diagnostics
- Scrub references (skipped tests and such) referencing this issue
- test
Obsoleteattribute (and related)- Diagnostics about attributes occur in local function locations
- test
Conditionalattribute- test
Conditionalwith bad target method (non-void returning)
- test
- test various nullability attributes
- test
[EnumeratorCancellation]attribute on parameter of async-iterator local function Support EnumeratorCancellationAttribute in local functions #40959 - MethodImplAttribute
- DllImportAttribute
-
static externlocal functions - local functions with no body
- ExcludeFromCodeCoverageAttribute Support ExcludeFromCodeCoverageAttribute in local functions #41129
- MarshalAsAttribute Support more well-known attributes in local functions #41299
- SkipLocalsInitAttribute Support SkipLocalsInitAttribute in local functions #41183
- test restricted attributes such as IsReadOnlyAttribute, IsUnmanaged, ExtensionAttribute, etc.
- Caller...Attribute Support more well-known attributes in local functions #41299
- LanguageVersion (tests added in Parse attributes on local function declarations #38808)
- Including in parameters
- Scoping inside full syntax (See LookupTests.cs)
- Scoping for attribute lists on incomplete statements Fill in test gaps for local-function-attributes #41379 (comment)
- Can't use locals inside attribute creation, e.g. calling other local functions, using captured variables
- Local constants should probably be valid
- Attribute argument with declaration pattern
- Attribute argument with call containing 'out var'
- Attribute constructor with
outparameter (disallowed)- Out to a local
- Out var
- Referencing local function with ConditionalAttribute only in a "dead" condition
#ifshould not produce unused warning - ConditionalAttribute should be disallowed on non-static local functions Disallow ConditionalAttribute on non-static local functions #41333
IDE:
- Test interactive typing
- Start with an attribute
- Completion
- Keyword recommendation (
extern)
Before merge:
- ConditionalAttribute disallowed on non-static local functions Disallow ConditionalAttribute on non-static local functions #41333
- IDE interactive testing
- AttributeUsage
- Prevent regressing EndToEndTests
- Draft spec checked into proposals, awaiting validation by Neal
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
Area-CompilersTestTest failures in roslyn-CITest failures in roslyn-CITest-GapDescribes a specific feature or scenario that does not have test coverageDescribes a specific feature or scenario that does not have test coverage