close
Skip to content

Commit 9562e85

Browse files
Clarify DyadicOperator::New (#180)
1 parent 9cee107 commit 9562e85

1 file changed

Lines changed: 6 additions & 3 deletions

File tree

‎ltx/exprs.tex‎

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2444,12 +2444,15 @@ \subsection{Dyadic operators}
24442444
and with a given initializer.
24452445

24462446
When used as the value of the \field{assoc} field of a \sortref{Dyadic}{ExprSort} structure,
2447-
that structure reprsents a \grammar{new-expression} of the form \code{new T(x)} or \code{new T{x}},
2447+
that structure reprsents a \grammar{new-expression} of the form \code{new T(x)} or \code{new T\{x\}},
24482448
and the \field{argument[0]} of that structure is an abstract reference designating the type \code{T}
2449-
and the \field{argument[1]} is an abstract reference designating the initializer (which can be an \grammar{expression-list}).
2449+
and the \field{argument[1]} is an abstract reference designating the initializer
2450+
(which can be an \grammar{expression-list}). None of these operands shall be null, even if the generate case
2451+
of the second operand being null can represent an expression of the form \code{new T}
2452+
(see \sortref{New}{MonadicOperator}).
24502453

24512454
\note{See also \sortref{LookupGlobally}{MonadicOperator} for the representation
2452-
of a \grammar{new-expression} with the global scope resolution operator (\code{::}) as prefix}
2455+
of a \grammar{new-expression} with the global scope resolution operator (\code{::}) as prefix}.
24532456

24542457
\ifcSortSection{NewArray}{DyadicOperator}
24552458
Abstract machine operation corresponding to allocating appropriate storage and default constructing an array of a given element type and length.

0 commit comments

Comments
 (0)