Skip to content

Commit fbab3f1

Browse files
[defns.access, basic.lval] Clarify what can be accessed and how (#4777)
1 parent 31c32e0 commit fbab3f1

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

source/expressions.tex

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -319,7 +319,9 @@
319319
that does not denote an object of type \cv{}~\keyword{U} within its lifetime,
320320
the behavior is undefined.
321321
\begin{note}
322-
Unlike in C, \Cpp{} has no accesses of class type.
322+
In C, an entire object of structure type can be accessed, e.g. using assignment.
323+
By contrast, \Cpp{} has no notion of accessing an object of class type
324+
through an lvalue of class type.
323325
\end{note}
324326

325327
\rSec2[expr.type]{Type}

source/intro.tex

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -137,9 +137,9 @@
137137
read or modify the value of an object
138138

139139
\begin{defnote}
140-
Only objects of scalar type can be accessed.
140+
Only glvalues of scalar type can be used to access objects.
141141
Reads of scalar objects are described in \ref{conv.lval} and
142-
modifications of scalar objects are describred in
142+
modifications of scalar objects are described in
143143
\ref{expr.ass}, \ref{expr.post.incr}, and \ref{expr.pre.incr}.
144144
Attempts to read or modify an object of class type
145145
typically invoke a constructor\iref{class.ctor}

0 commit comments

Comments
 (0)