Skip to content

Commit 2d8f848

Browse files
committed
Adjust examples declaring non-nullable positional optional parameters with no default
1 parent e051c5b commit 2d8f848

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
@@ -3393,7 +3393,7 @@ \subsubsection{The Method \code{noSuchMethod}}
33933393
in order to correctly override \code{noSuchMethod} in \code{Object}.
33943394
For instance, it can have signature
33953395
\code{noSuchMethod(Invocation i)} or
3396-
\code{noSuchMethod(Object i, [String s = ''])},
3396+
\code{noSuchMethod(Object i, [String? s])},
33973397
but not
33983398
\code{noSuchMethod(Invocation i, String s)}.
33993399
This implies that the situation where \code{noSuchMethod} is invoked
@@ -4164,7 +4164,7 @@ \subsubsection{Generative Constructors}
41644164

41654165
\begin{dartCode}
41664166
class A \{
4167-
int x;
4167+
int? x;
41684168
A([this.x]);
41694169
\}
41704170
\end{dartCode}
@@ -4175,8 +4175,8 @@ \subsubsection{Generative Constructors}
41754175

41764176
\begin{dartCode}
41774177
class A \{
4178-
int x;
4179-
A([int x]): this.x = x;
4178+
int? x;
4179+
A([int? x]): this.x = x;
41804180
\}
41814181
\end{dartCode}
41824182

@@ -15632,7 +15632,7 @@ \subsubsection{Generic Method Instantiation}
1563215632
\}
1563315633
\\
1563415634
\CLASS{} B \EXTENDS{} /*\,or\,\,\IMPLEMENTS\,*/ A \{
15635-
X fi<X \EXTENDS{} num>(X x, [List<X> xs]) => x;
15635+
X fi<X \EXTENDS{} num>(X x, [List<X>? xs]) => x;
1563615636
\}
1563715637
\\
1563815638
\VOID{} main() \{
@@ -15644,7 +15644,7 @@ \subsubsection{Generic Method Instantiation}
1564415644
\commentary{%
1564515645
\noindent
1564615646
The function object that \code{f} is bound to at the end of \code{main}
15647-
has dynamic type \code{int\,\,\FUNCTION(int,\,[List<int>])},
15647+
has dynamic type \code{int\,\,\FUNCTION(int,\,[List<int>?])},
1564815648
and it is obtained by implicitly
1564915649
``passing the actual type argument \code{int}''
1565015650
to the denoted generic instance method,

0 commit comments

Comments
 (0)