OLD | NEW |
1 \documentclass{article} | 1 \documentclass{article} |
2 \usepackage{epsfig} | 2 \usepackage{epsfig} |
3 \usepackage{dart} | 3 \usepackage{dart} |
4 \usepackage{bnf} | 4 \usepackage{bnf} |
5 \usepackage{hyperref} | 5 \usepackage{hyperref} |
6 \newcommand{\code}[1]{{\sf #1}} | 6 \newcommand{\code}[1]{{\sf #1}} |
7 \title{Dart Programming Language Specification \\ | 7 \title{Dart Programming Language Specification \\ |
8 {\large Version 1.2}} | 8 {\large Version 1.2}} |
9 \author{The Dart Team} | 9 \author{The Dart Team} |
10 \begin{document} | 10 \begin{document} |
11 \maketitle | 11 \maketitle |
12 | 12 |
13 \tableofcontents | 13 \tableofcontents |
14 | 14 |
15 | 15 |
16 \newpage | 16 \newpage |
17 | 17 |
18 \pagestyle{myheadings} | 18 \pagestyle{myheadings} |
19 \markright{Dart Programming Language Specification} | 19 \markright{Dart Programming Language Specification} |
20 | 20 |
21 \section{Notes} | 21 \section{Notes} |
22 | 22 |
23 \subsection{Licensing} | 23 \subsection{Licensing} |
24 \label{licensing} | 24 \label{licensing} |
25 | 25 |
26 | 26 |
27 Except as otherwise noted at http://code.google.com/policies.html\#restrictions,
the content of this document is licensed under the Creative Commons Attribution
3.0 License available at: | 27 Except as otherwise noted at https://developers.google.com/site-policies, the co
ntent of this document is licensed under the Creative Commons Attribution 3.0 Li
cense available at: |
28 | 28 |
29 http://creativecommons.org/licenses/by/3.0/ | 29 http://creativecommons.org/licenses/by/3.0/ |
30 | 30 |
31 and code samples are licensed under the BSD license available at | 31 and code samples are licensed under the license available at |
32 | 32 |
33 http://code.google.com/google\_bsd\_license.html. | 33 https://code.google.com/p/dart/source/browse/trunk/dart/LICENSE. |
34 | 34 |
35 \section{Notation} | 35 \section{Notation} |
36 \label{notation} | 36 \label{notation} |
37 | 37 |
38 We distinguish between normative and non-normative text. Normative text defines
the rules of Dart. It is given in this font. At this time, non-normative text in
cludes: | 38 We distinguish between normative and non-normative text. Normative text defines
the rules of Dart. It is given in this font. At this time, non-normative text in
cludes: |
39 \begin{itemize} | 39 \begin{itemize} |
40 \item[Rationale] Discussion of the motivation for language design decisions appe
ars in italics. \rationale{Distinguishing normative from non-normative helps cla
rify what part of the text is binding and what part is merely expository.} | 40 \item[Rationale] Discussion of the motivation for language design decisions appe
ars in italics. \rationale{Distinguishing normative from non-normative helps cla
rify what part of the text is binding and what part is merely expository.} |
41 \item[Commentary] Comments such as ``\commentary{The careful reader will have n
oticed that the name Dart has four characters}'' serve to illustrate or clarify
the specification, but are redundant with the normative text. \commentary{The d
ifference between commentary and rationale can be subtle.} \rationale{ Commentar
y is more general than rationale, and may include illustrative examples or clari
fications. } | 41 \item[Commentary] Comments such as ``\commentary{The careful reader will have n
oticed that the name Dart has four characters}'' serve to illustrate or clarify
the specification, but are redundant with the normative text. \commentary{The d
ifference between commentary and rationale can be subtle.} \rationale{ Commentar
y is more general than rationale, and may include illustrative examples or clari
fications. } |
42 \item[Open questions] (\Q{in this font}). Open questions are points that are uns
ettled in the mind of the author(s) of the specification; expect them (the quest
ions, not the authors; precision is important in a specification) to be eliminat
ed in the final specification. \Q{Should the text at the end of the previous bul
let be rationale or commentary?} | 42 \item[Open questions] (\Q{in this font}). Open questions are points that are uns
ettled in the mind of the author(s) of the specification; expect them (the quest
ions, not the authors; precision is important in a specification) to be eliminat
ed in the final specification. \Q{Should the text at the end of the previous bul
let be rationale or commentary?} |
43 \end{itemize} | 43 \end{itemize} |
(...skipping 869 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
913 It is a static warning if a setter declares a return type other than \VOID{}. | 913 It is a static warning if a setter declares a return type other than \VOID{}. |
914 It is a static warning if a setter $m_1$ overrides (\ref{inheritanceAndOverridi
ng}) a setter $m_2$ and the type of $m_1$ is not a subtype of the type of $m_2$.
It is a static warning if a class has a setter named $v=$ with argument type $T
$ and a getter named $v$ with return type $S$, and $T$ may not be assigned to $S
$. | 914 It is a static warning if a setter $m_1$ overrides (\ref{inheritanceAndOverridi
ng}) a setter $m_2$ and the type of $m_1$ is not a subtype of the type of $m_2$.
It is a static warning if a class has a setter named $v=$ with argument type $T
$ and a getter named $v$ with return type $S$, and $T$ may not be assigned to $S
$. |
915 | 915 |
916 It is a static warning if a class declares a static setter named $v=$ and also
has a non-static member named $v$. It is a static warning if a class $C$ declare
s an instance setter named $v=$ and an accessible static member named $v=$ or $v
$ is declared in a superclass of $C$. | 916 It is a static warning if a class declares a static setter named $v=$ and also
has a non-static member named $v$. It is a static warning if a class $C$ declare
s an instance setter named $v=$ and an accessible static member named $v=$ or $v
$ is declared in a superclass of $C$. |
917 | 917 |
918 These warnings must be issued regardless of whether the getters or setters are d
eclared explicitly or implicitly. | 918 These warnings must be issued regardless of whether the getters or setters are d
eclared explicitly or implicitly. |
919 | 919 |
920 \subsection{Abstract Instance Members} | 920 \subsection{Abstract Instance Members} |
921 \label{abstractInstanceMembers} | 921 \label{abstractInstanceMembers} |
922 | 922 |
923 An {\em abstract method} (respectively, {\em abstract getter} or {\em abstract s
etter)} is an instance method, getter or setter that is not declared \EXTERNAL{}
and does not provide an implementation. An {\em concrete method} (respectively
, {\em concrete getter} or {\em concrete setter)} is an instance method, getter
or setter that is not abstract. | 923 An {\em abstract method} (respectively, {\em abstract getter} or {\em abstract s
etter)} is an instance method, getter or setter that is not declared \EXTERNAL{}
and does not provide an implementation. A {\em concrete method} (respectively,
{\em concrete getter} or {\em concrete setter)} is an instance method, getter o
r setter that is not abstract. |
924 %The declaration of an abstract method is prefixed by the built-in identifier (\
ref{identifierReference}) \ABSTRACT{}. | 924 %The declaration of an abstract method is prefixed by the built-in identifier (\
ref{identifierReference}) \ABSTRACT{}. |
925 | 925 |
926 \rationale{ | 926 \rationale{ |
927 Earlier versions of Dart required that abstract members be identified by prefixi
ng them with the modifier \ABSTRACT{}. The elimination of this requirement is m
otivated by the desire to use abstract classes as interfaces. Every Dart class i
nduces an implicit interface. | 927 Earlier versions of Dart required that abstract members be identified by prefixi
ng them with the modifier \ABSTRACT{}. The elimination of this requirement is m
otivated by the desire to use abstract classes as interfaces. Every Dart class i
nduces an implicit interface. |
928 | 928 |
929 Using an abstract class instead of an interface has important advantages. An abs
tract class can provide default implementations; it can also provide static meth
ods, obviating the need for service classes such as \code{Collections} or \code{
Lists}, whose entire purpose is to group utilities related to a given type. | 929 Using an abstract class instead of an interface has important advantages. An abs
tract class can provide default implementations; it can also provide static meth
ods, obviating the need for service classes such as \code{Collections} or \code{
Lists}, whose entire purpose is to group utilities related to a given type. |
930 | 930 |
931 Eliminating the requirement for an explicit modifier on members makes abstract c
lasses more concise, making abstract classes an attractive substitute for inter
face declarations. | 931 Eliminating the requirement for an explicit modifier on members makes abstract c
lasses more concise, making abstract classes an attractive substitute for inter
face declarations. |
932 } | 932 } |
933 | 933 |
(...skipping 654 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1588 It is a compile-time error if the \IMPLEMENTS{} clause of a class $C$ specifie
s a type variable as a superinterface. It is a compile-time error if the \IMPL
EMENTS{} clause of a class $C$ specifies a malformed type as a superinterface
It is a compile-time error if the \IMPLEMENTS{} clause of a class $C$ specifies
type \DYNAMIC{} as a superinterface. It is a compile-time error if the \IMPLEM
ENTS{} clause of a class $C$ specifies a type $T$ as a superinterface more than
once. | 1588 It is a compile-time error if the \IMPLEMENTS{} clause of a class $C$ specifie
s a type variable as a superinterface. It is a compile-time error if the \IMPL
EMENTS{} clause of a class $C$ specifies a malformed type as a superinterface
It is a compile-time error if the \IMPLEMENTS{} clause of a class $C$ specifies
type \DYNAMIC{} as a superinterface. It is a compile-time error if the \IMPLEM
ENTS{} clause of a class $C$ specifies a type $T$ as a superinterface more than
once. |
1589 It is a compile-time error if the superclass of a class $C$ is specified as a su
perinterface of $C$. | 1589 It is a compile-time error if the superclass of a class $C$ is specified as a su
perinterface of $C$. |
1590 | 1590 |
1591 \rationale{ | 1591 \rationale{ |
1592 One might argue that it is harmless to repeat a type in the superinterface list,
so why make it an error? The issue is not so much that the situation described
in program source is erroneous, but that it is pointless. As such, it is an indi
cation that the programmer may very well have meant to say something else - and
that is a mistake that should be called to her or his attention. Nevertheless,
we could simply issue a warning; and perhaps we should and will. That said, prob
lems like these are local and easily corrected on the spot, so we feel justified
in taking a harder line. | 1592 One might argue that it is harmless to repeat a type in the superinterface list,
so why make it an error? The issue is not so much that the situation described
in program source is erroneous, but that it is pointless. As such, it is an indi
cation that the programmer may very well have meant to say something else - and
that is a mistake that should be called to her or his attention. Nevertheless,
we could simply issue a warning; and perhaps we should and will. That said, prob
lems like these are local and easily corrected on the spot, so we feel justified
in taking a harder line. |
1593 } | 1593 } |
1594 | 1594 |
1595 It is a compile-time error if the interface of a class $C$ is a superinterface o
f itself. | 1595 It is a compile-time error if the interface of a class $C$ is a superinterface o
f itself. |
1596 | 1596 |
1597 Let $C$ be a concrete class that does not declare its own \code{noSuchMethod()}
method. | 1597 Let $C$ be a concrete class that does not declare its own \code{noSuchMethod()}
method. |
1598 It is a static warning if the implicit interface of $C$ includes an instance me
mber $m$ of type $F$ and $C$ does not declare or inherit a corresponding instanc
e member $m$ of type $F'$ such that $F' <: F$. | 1598 It is a static warning if the implicit interface of $C$ includes an instance me
mber $m$ of type $F$ and $C$ does not declare or inherit a corresponding non-abs
tract instance member $m$ of type $F'$ such that $F' <: F$. |
1599 | 1599 |
1600 \commentary{A class does not inherit members from its superinterfaces. However,
its implicit interface does. | 1600 \commentary{A class does not inherit members from its superinterfaces. However,
its implicit interface does. |
1601 } | 1601 } |
1602 | 1602 |
1603 | 1603 |
1604 \rationale { | 1604 \rationale { |
1605 We choose to issue these warnings only for concrete classes; an abstract class m
ight legitimately be designed with the expectation that concrete subclasses will
implement part of the interface. | 1605 We choose to issue these warnings only for concrete classes; an abstract class m
ight legitimately be designed with the expectation that concrete subclasses will
implement part of the interface. |
1606 We also disable these warnings if a \code{noSuchMethod()} declaration is present
. In such cases, the supported interface is going to be implemented via \code{no
SuchMethod()} and no actual declarations of the implemented interface's members
are needed. This allows proxy classes for specific types to be implemented witho
ut provoking type warnings. | 1606 We also disable these warnings if a \code{noSuchMethod()} declaration is present
. In such cases, the supported interface is going to be implemented via \code{no
SuchMethod()} and no actual declarations of the implemented interface's members
are needed. This allows proxy classes for specific types to be implemented witho
ut provoking type warnings. |
1607 | 1607 |
1608 In addition, it may be useful to suppress these warnings if \code{noSuchMethod}
is inherited, However, this may suppress meaningful warnings and so we choose no
t to do so. If one does want to suppress the warnings in a subclass, one can def
ine a simple implementation of \code{noSuchMethod} in the subclass: | 1608 In addition, it may be useful to suppress these warnings if \code{noSuchMethod}
is inherited, However, this may suppress meaningful warnings and so we choose no
t to do so. If one does want to suppress the warnings in a subclass, one can def
ine a simple implementation of \code{noSuchMethod} in the subclass: |
(...skipping 1564 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3173 \item \code{im.memberName} evaluates to \code{'m'}. | 3173 \item \code{im.memberName} evaluates to \code{'m'}. |
3174 \item \code{im.positionalArguments} evaluates to an immutable list with the same
values as \code{[$o_1, \ldots, o_n$]}. | 3174 \item \code{im.positionalArguments} evaluates to an immutable list with the same
values as \code{[$o_1, \ldots, o_n$]}. |
3175 \item \code{im.namedArguments} evaluates to an immutable map with the same keys
and values as \code{\{$x_{n+1}: o_{n+1}, \ldots, x_{n+k} : o_{n+k}$\}}. | 3175 \item \code{im.namedArguments} evaluates to an immutable map with the same keys
and values as \code{\{$x_{n+1}: o_{n+1}, \ldots, x_{n+k} : o_{n+k}$\}}. |
3176 \end{itemize} | 3176 \end{itemize} |
3177 | 3177 |
3178 Then the method \code{noSuchMethod()} is looked up in $o$ and invoked with argum
ent $im$, and the result of this invocation is the result of evaluating $i$. | 3178 Then the method \code{noSuchMethod()} is looked up in $o$ and invoked with argum
ent $im$, and the result of this invocation is the result of evaluating $i$. |
3179 | 3179 |
3180 \commentary{Notice that the wording carefully avoids re-evaluating the receiver
$o$ and the arguments $a_i$. } | 3180 \commentary{Notice that the wording carefully avoids re-evaluating the receiver
$o$ and the arguments $a_i$. } |
3181 | 3181 |
3182 Let $T$ be the static type of $o$. It is a static type warning if $T$ does not
have an accessible (\ref{privacy}) instance member named $m$ unless $T$ or a su
perinterface of $T$ is annotated with an annotation denoting a constant identica
l to the constant \code{@proxy} defined in \code{dart:core}. If $T.m$ exists,
it is a static type warning if the type $F$ of $T.m$ may not be assigned to a f
unction type. If $T.m$ does not exist, or if $F$ is not a function type, the sta
tic type of $i$ is \DYNAMIC{}; otherwise the static type of $i$ is the declared
return type of $F$. | 3182 Let $T$ be the static type of $o$. It is a static type warning if $T$ does not
have an accessible (\ref{privacy}) instance member named $m$ unless $T$ or a su
perinterface of $T$ is annotated with an annotation denoting a constant identica
l to the constant \code{@proxy} defined in \code{dart:core}. If $T.m$ exists,
it is a static type warning if the type $F$ of $T.m$ may not be assigned to a f
unction type. If $T.m$ does not exist, or if $F$ is not a function type, the sta
tic type of $i$ is \DYNAMIC{}; otherwise the static type of $i$ is the declared
return type of $F$. |
3183 %\item Let $T_i$ be the static type of $a_i, i \in 1 .. n+k$. It is a static war
ning if $F$ is not a supertype of $(T_1, \ldots, T_n, [T_{n+1}$ $x_{n+1}, \ldot
s, T_{n+k}$ $x_{n+k}]) \to \bot$. | 3183 % The following is not needed because it is specified in 'Binding Actuals to For
mals" Let $T_i$ be the static type of $a_i, i \in 1 .. n+k$. It is a static warn
ing if $F$ is not a supertype of $(T_1, \ldots, T_n, \{T_{n+1}$ $x_{n+1}, \ldot
s, T_{n+k}$ $x_{n+k}\}) \to \bot$. |
3184 %\end{itemize} | 3184 |
3185 | 3185 |
3186 | 3186 |
3187 %\subsubsection{This Invocation} | 3187 %\subsubsection{This Invocation} |
3188 % Maybe this has no significance the way the language is set up? | 3188 % Maybe this has no significance the way the language is set up? |
3189 | 3189 |
3190 | 3190 |
3191 \subsubsection{Cascaded Invocations} | 3191 \subsubsection{Cascaded Invocations} |
3192 \label{cascadedInvocations} | 3192 \label{cascadedInvocations} |
3193 | 3193 |
3194 A {\em cascaded method invocation} has the form {\em e..suffix} | 3194 A {\em cascaded method invocation} has the form {\em e..suffix} |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3233 Otherwise, evaluation proceeds as follows: | 3233 Otherwise, evaluation proceeds as follows: |
3234 \begin{itemize} | 3234 \begin{itemize} |
3235 \item | 3235 \item |
3236 If the member $m$ declared by $C$ is a getter, then $i$ is equivalent to the exp
ression $(C.m)(a_1, \ldots , a_n, x_{n+1}: a_{n+1}, \ldots , x_{n+k}: a_{n+k})$.
| 3236 If the member $m$ declared by $C$ is a getter, then $i$ is equivalent to the exp
ression $(C.m)(a_1, \ldots , a_n, x_{n+1}: a_{n+1}, \ldots , x_{n+k}: a_{n+k})$.
|
3237 \item Otherwise, let $f$ be the the method $m$ declared in class $C$. Next, the
argument list $(a_1, \ldots , a_n, x_{n+1}: a_{n+1}, \ldots , x_{n+k}: a_{n+k})$
is evaluated. | 3237 \item Otherwise, let $f$ be the the method $m$ declared in class $C$. Next, the
argument list $(a_1, \ldots , a_n, x_{n+1}: a_{n+1}, \ldots , x_{n+k}: a_{n+k})$
is evaluated. |
3238 The body of $f$ is then executed with respect to the bindings that resulted from
the evaluation of the argument list. The value of $i$ is the value returned aft
er the body of $f$ is executed. | 3238 The body of $f$ is then executed with respect to the bindings that resulted from
the evaluation of the argument list. The value of $i$ is the value returned aft
er the body of $f$ is executed. |
3239 \end{itemize} | 3239 \end{itemize} |
3240 | 3240 |
3241 It is a static type warning if the type $F$ of $C.m$ may not be assigned to a fu
nction type. If $F$ is not a function type, or if $C.m$ does not exist, the sta
tic type of $i$ is \DYNAMIC{}. Otherwise | 3241 It is a static type warning if the type $F$ of $C.m$ may not be assigned to a fu
nction type. If $F$ is not a function type, or if $C.m$ does not exist, the sta
tic type of $i$ is \DYNAMIC{}. Otherwise |
3242 the static type of $i$ is the declared return type of $F$. | 3242 the static type of $i$ is the declared return type of $F$. |
3243 %\item Let $T_i$ be the static type of $a_i, i \in 1 .. n+k$. It is a static war
ning if $F$ is not a supertype of $(T_1, \ldots, T_n, [T_{n+1}$ $x_{n+1}, \ldot
s, T_{n+k}$ $x_{n+k}]) \to \bot$. | 3243 % The following is not needed because it is specified in 'Binding Actuals to For
mals"Let $T_i$ be the static type of $a_i, i \in 1 .. n+k$. It is a static warni
ng if $F$ is not a supertype of $(T_1, \ldots, T_n, \{T_{n+1}$ $x_{n+1}, \ldots
, T_{n+k}$ $x_{n+k}\}) \to \bot$. |
3244 %\end{itemize} | 3244 |
3245 | 3245 |
3246 | 3246 |
3247 | 3247 |
3248 \subsubsection{Super Invocation} | 3248 \subsubsection{Super Invocation} |
3249 \label{superInvocation} | 3249 \label{superInvocation} |
3250 | 3250 |
3251 A super method invocation $i$ has the form | 3251 A super method invocation $i$ has the form |
3252 | 3252 |
3253 $\SUPER{}.m(a_1, \ldots , a_n, x_{n+1}: a_{n+1}, \ldots , x_{n+k}: a_{n+k})$. | 3253 $\SUPER{}.m(a_1, \ldots , a_n, x_{n+1}: a_{n+1}, \ldots , x_{n+k}: a_{n+k})$. |
3254 | 3254 |
(...skipping 14 matching lines...) Expand all Loading... |
3269 \item \code{im.isMethod} evaluates to \code{\TRUE{}}. | 3269 \item \code{im.isMethod} evaluates to \code{\TRUE{}}. |
3270 \item \code{im.memberName} evaluates to \code{'m'}. | 3270 \item \code{im.memberName} evaluates to \code{'m'}. |
3271 \item \code{im.positionalArguments} evaluates to an immutable list with the same
values as \code{[$o_1, \ldots, o_n$]}. | 3271 \item \code{im.positionalArguments} evaluates to an immutable list with the same
values as \code{[$o_1, \ldots, o_n$]}. |
3272 \item \code{im.namedArguments} evaluates to an immutable map with the same keys
and values as \code{\{$x_{n+1}: o_{n+1}, \ldots, x_{n+k} : o_{n+k}$\}}. | 3272 \item \code{im.namedArguments} evaluates to an immutable map with the same keys
and values as \code{\{$x_{n+1}: o_{n+1}, \ldots, x_{n+k} : o_{n+k}$\}}. |
3273 \end{itemize} | 3273 \end{itemize} |
3274 Then the method \code{noSuchMethod()} is looked up in $S$ and invoked on \THIS{}
with argument $im$, and the result of this invocation is the result of evaluati
ng $i$. | 3274 Then the method \code{noSuchMethod()} is looked up in $S$ and invoked on \THIS{}
with argument $im$, and the result of this invocation is the result of evaluati
ng $i$. |
3275 | 3275 |
3276 It is a compile-time error if a super method invocation occurs in a top-level fu
nction or variable initializer, in an instance variable initializer or initializ
er list, in class \code{Object}, in a factory constructor or in a static method
or variable initializer. | 3276 It is a compile-time error if a super method invocation occurs in a top-level fu
nction or variable initializer, in an instance variable initializer or initializ
er list, in class \code{Object}, in a factory constructor or in a static method
or variable initializer. |
3277 | 3277 |
3278 It is a static type warning if $S$ does not have an accessible (\ref{privacy}) i
nstance member named $m$ unless $S$ or a superinterface of $S$ is annotated with
an annotation denoting a constant identical to the constant \code{@proxy} defin
ed in \code{dart:core}. If $S.m$ exists, it is a static type warning if the typ
e $F$ of $S.m$ may not be assigned to a function type. If $S.m$ does not exist,
or if $F$ is not a function type, the static type of $i$ is \DYNAMIC{}; otherwis
e the static type of $i$ is the declared return type of $F$. | 3278 It is a static type warning if $S$ does not have an accessible (\ref{privacy}) i
nstance member named $m$ unless $S$ or a superinterface of $S$ is annotated with
an annotation denoting a constant identical to the constant \code{@proxy} defin
ed in \code{dart:core}. If $S.m$ exists, it is a static type warning if the typ
e $F$ of $S.m$ may not be assigned to a function type. If $S.m$ does not exist,
or if $F$ is not a function type, the static type of $i$ is \DYNAMIC{}; otherwis
e the static type of $i$ is the declared return type of $F$. |
3279 %\item Let $T_i$ be the static type of $a_i, i \in 1 .. n+k$. It is a static war
ning if $F$ is not a supertype of $(T_1, \ldots, t_n, [T_{n+1}$ $x_{n+1}, \ldot
s, T_{n+k}$ $x_{n+k}]) \to \bot$. | 3279 % The following is not needed because it is specified in 'Binding Actuals to For
mals" |
3280 %\end{itemize} | 3280 %Let $T_i$ be the static type of $a_i, i \in 1 .. n+k$. It is a static warning i
f $F$ is not a supertype of $(T_1, \ldots, t_n, \{T_{n+1}$ $x_{n+1}, \ldots, T_
{n+k}$ $x_{n+k}\}) \to \bot$. |
| 3281 |
3281 | 3282 |
3282 | 3283 |
3283 | 3284 |
3284 \subsubsection{Sending Messages} | 3285 \subsubsection{Sending Messages} |
3285 | 3286 |
3286 \label{sendingMessages} | 3287 \label{sendingMessages} |
3287 | 3288 |
3288 Messages are the sole means of communication among isolates. Messages are sent b
y invoking specific methods in the Dart libraries; there is no specific syntax
for sending a message. | 3289 Messages are the sole means of communication among isolates. Messages are sent b
y invoking specific methods in the Dart libraries; there is no specific syntax
for sending a message. |
3289 | 3290 |
3290 \commentary{In other words, the methods supporting sending messages embody primi
tives of Dart that are not accessible to ordinary code, much like the methods th
at spawn isolates. | 3291 \commentary{In other words, the methods supporting sending messages embody primi
tives of Dart that are not accessible to ordinary code, much like the methods th
at spawn isolates. |
(...skipping 2550 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5841 \item The names of compile time constant variables never use lower case letters.
If they consist of multiple words, those words are separated by underscores. Ex
amples: PI, I\_AM\_A\_CONSTANT. | 5842 \item The names of compile time constant variables never use lower case letters.
If they consist of multiple words, those words are separated by underscores. Ex
amples: PI, I\_AM\_A\_CONSTANT. |
5842 \item The names of functions (including getters, setters, methods and local or l
ibrary functions) and non-constant variables begin with a lowercase letter. If t
he name consists of multiple words, each word (except the first) begins with an
uppercase letter. No other uppercase letters are used. Examples: camlCase, dar
t4TheWorld | 5843 \item The names of functions (including getters, setters, methods and local or l
ibrary functions) and non-constant variables begin with a lowercase letter. If t
he name consists of multiple words, each word (except the first) begins with an
uppercase letter. No other uppercase letters are used. Examples: camlCase, dar
t4TheWorld |
5843 \item The names of types (including classes and type aliases) begin with an uppe
r case letter. If the name consists of multiple words, each word begins with
an uppercase letter. No other uppercase letters are used. Examples: CamlCase, D
art4TheWorld. | 5844 \item The names of types (including classes and type aliases) begin with an uppe
r case letter. If the name consists of multiple words, each word begins with
an uppercase letter. No other uppercase letters are used. Examples: CamlCase, D
art4TheWorld. |
5844 \item The names of type variables are short (preferably single letter). Examples
: T, S, K, V , E. | 5845 \item The names of type variables are short (preferably single letter). Examples
: T, S, K, V , E. |
5845 \item The names of libraries or library prefixes never use upper case letters. I
f they consist of multiple words, those words are separated by underscores. Exam
ple: my\_favorite\_library. | 5846 \item The names of libraries or library prefixes never use upper case letters. I
f they consist of multiple words, those words are separated by underscores. Exam
ple: my\_favorite\_library. |
5846 \end{itemize} | 5847 \end{itemize} |
5847 } | 5848 } |
5848 | 5849 |
5849 | 5850 |
5850 \end{document} | 5851 \end{document} |
OLD | NEW |