Skip to content

Commit f7c7866

Browse files
committed
Adjust examples declaring non-nullable positional optional parameters with no default
1 parent 0d46192 commit f7c7866

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

specification/dartLangSpec.tex

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3215,7 +3215,7 @@ \subsubsection{The Method \code{noSuchMethod}}
32153215
in order to correctly override \code{noSuchMethod} in \code{Object}.
32163216
For instance, it can have signature
32173217
\code{noSuchMethod(Invocation i)} or
3218-
\code{noSuchMethod(Object i, [String s])},
3218+
\code{noSuchMethod(Object i, [String? s])},
32193219
but not
32203220
\code{noSuchMethod(Invocation i, String s)}.
32213221
This implies that the situation where \code{noSuchMethod} is invoked
@@ -3961,7 +3961,7 @@ \subsubsection{Generative Constructors}
39613961

39623962
\begin{dartCode}
39633963
class A \{
3964-
int x;
3964+
int? x;
39653965
A([this.x]);
39663966
\}
39673967
\end{dartCode}
@@ -3972,8 +3972,8 @@ \subsubsection{Generative Constructors}
39723972

39733973
\begin{dartCode}
39743974
class A \{
3975-
int x;
3976-
A([int x]): this.x = x;
3975+
int? x;
3976+
A([int? x]): this.x = x;
39773977
\}
39783978
\end{dartCode}
39793979

@@ -15242,7 +15242,7 @@ \subsubsection{Generic Method Instantiation}
1524215242
\}
1524315243
\\
1524415244
\CLASS{} B \EXTENDS{} /*\,or\,\,\IMPLEMENTS\,*/ A \{
15245-
X fi<X \EXTENDS{} num>(X x, [List<X> xs]) => x;
15245+
X fi<X \EXTENDS{} num>(X x, [List<X>? xs]) => x;
1524615246
\}
1524715247
\\
1524815248
\VOID{} main() \{
@@ -15254,7 +15254,7 @@ \subsubsection{Generic Method Instantiation}
1525415254
\commentary{%
1525515255
\noindent
1525615256
The function object that \code{f} is bound to at the end of \code{main}
15257-
has dynamic type \code{int\,\,\FUNCTION(int,\,[List<int>])},
15257+
has dynamic type \code{int\,\,\FUNCTION(int,\,[List<int>?])},
1525815258
and it is obtained by implicitly
1525915259
``passing the actual type argument \code{int}''
1526015260
to the denoted generic instance method,

0 commit comments

Comments
 (0)