Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[dcl.fct,expr.ref] Fix description of class member access expressions #3624

Merged
merged 1 commit into from Jan 14, 2020

Conversation

jensmaurer
Copy link
Member

involving non-static member functions.

Fixes #3607.

source/expressions.tex Outdated Show resolved Hide resolved
@zygoloid zygoloid added the changes requested Changes to the wording or approach have been requested and not yet applied. label Jan 13, 2020
@jensmaurer jensmaurer removed the changes requested Changes to the wording or approach have been requested and not yet applied. label Jan 13, 2020
Comment on lines 3282 to 3283
If \tcode{E2} refers to a member function of type \tcode{T},
\tcode{E1.E2} has type \tcode{T} and refers to that member function.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The "If" here sounds like it's introducing a condition, but it's not. Perhaps:

If E2 is a (possibly overloaded) member function, function overload resolution ([over.match]) is used to determine to which function E2 refers. The type of E1.E2 is the type of E2 and E1.E2 refers to the function referred to by E2."

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed with a slightly bigger hammer.

member function. The type of \tcode{E1.E2} is the same type as that of
\tcode{E2}, namely ``function of parameter-type-list returning
\tcode{T}''.
\item If \tcode{E1.E2} refers to a static member function,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think "If E2 refers to a static member function" would be a little simpler.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed.

Comment on lines 3289 to 3290
\item Otherwise, if \tcode{E1.E2} refers to a non-static member function,
then \tcode{E1.E2} is a prvalue. The expression can be used only as the
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe:

Otherwise (when E2 refers to a non-static member function), E1.E2 is a prvalue.

@zygoloid zygoloid added the changes requested Changes to the wording or approach have been requested and not yet applied. label Jan 13, 2020
@jensmaurer jensmaurer removed the changes requested Changes to the wording or approach have been requested and not yet applied. label Jan 14, 2020
@zygoloid zygoloid merged commit 54dc015 into cplusplus:master Jan 14, 2020
@jensmaurer jensmaurer deleted the c36 branch January 15, 2020 22:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[expr.ref]/(6.3.2) function type spelling doesn't match [dcl.fct]/1
2 participants