Skip to content

[basic.def.odr] p10 What does function definition scope mean in this current draft? #5406

@xmh0511

Description

@xmh0511

[basic.def.odr] p10 says

where *this is considered to be introduced within the innermost enclosing class or non-lambda function definition scope

And the comment in the example after this rule also refers to "function definition scope"

error: n is not odr-usable due to intervening function definition scope

In the subclause [basic.scope], we do not define "function definition scope", we just have function parameter scope. Does "function definition scope" intend to refer to function parameter scope instead?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions