Skip to content

There's potentially more than one function named main, and recursion is forbidden to a well-known one of them #261

@villevoutilainen

Description

@villevoutilainen

5.2.2 [expr.call]/9 says
"Recursive calls are permitted, except to the function named main (3.6.1)."
Since there's that cross-reference, it's otherwise correct, but I'd prefer it
to say "to the main function" instead of "to the function named main", since
nothing prevents me from having functions named main in user-defined namespaces
or as member functions of classes.

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