Skip to content

This needs more details on the reason for the error #40067

Open

Description

Type of issue

Missing information

Description

The description of the error is somewhat misleading. An enumerator method can't mix yield return and return statements. A single return for an object that implements the interface is allowed.

This article should also discuss how IAsyncEnumerable<T> works for these methods as well.

Page URL

https://learn.microsoft.com/en-us/dotnet/csharp/misc/cs1622

Content source URL

https://github.com/dotnet/docs/blob/main/docs/csharp/misc/cs1622.md

Document Version Independent Id

393a44fe-2f58-bc19-33c2-5da5504988c0

Article author

@BillWagner

Metadata

  • ID: e140b315-cdd1-3755-97cc-a6b9aa65db21
  • Service: dotnet-csharp
  • Sub-service: errors-warnings
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    Pri2doc-bugProblem with the content; needs to be fixed [org][type][category]dotnet-csharp/svcerrors-warnings/subsvcokr-healthokr-qualityContent-quality KR: Concerns article defects (bugs), freshness, or build warnings.user-feedbackIssues related to "Unified User Feedback".

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions