Skip to content

Commit 9f368f8

Browse files
committed
Adjust rules to make all private collisions an error (abstract/concrete/stub does not matter)
1 parent ecb4102 commit 9f368f8

File tree

1 file changed

+9
-4
lines changed

1 file changed

+9
-4
lines changed

specification/dartLangSpec.tex

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,8 @@
3333
% is a compile-time error except when it is a getter/setter pair.
3434
% - Change grammar to enable non-function type aliases. Correct rule for
3535
% invoking `F.staticMethod()` where `F` is a type alias.
36+
% - Clarify rules about error on mixin application involving private
37+
% members in different library.
3638
%
3739
% 2.8 - 2.10
3840
% - Change several warnings to compile-time errors, matching the actual
@@ -5496,17 +5498,20 @@ \subsection{Mixin Application}
54965498
\LMHash{}%
54975499
Let \DefineSymbol{L_C} be the library containing the mixin application.
54985500
\commentary{%
5499-
That is, the library containing the clause \code{$S$ \WITH{} $M$}
5500-
or the clause \code{$S_0$ \WITH{} $M_1$, \ldots,\ $M_k$, $M$} giving rise
5501-
to the mixin application.%
5501+
That is, the library containing the clause
5502+
\code{$S_0$ \WITH{} \List{M}{1}{k}} where
5503+
$M$ is $M_j$ and
5504+
$S$ is \code{$S_0$ \WITH{} \List{M}{1}{j - 1}},
5505+
for some $j \in 1 .. k$
5506+
(so for $j = 1$ we have \code{$S$ \WITH{} $M$, \ldots}).%
55025507
}
55035508
Let \DefineSymbol{L_M} be the library containing the declaration of $M$.
55045509

55055510
\LMHash{}%
55065511
Assume that $S$ has a concrete member $m_S$ which is accessible to $L_M$,
55075512
that $m_S$ has the name $n$ which is private
55085513
(\commentary{so $m_S$ is declared in $L_M$}),
5509-
and that $M$ declares a concrete member $m_M$ which is also named $n$
5514+
and that $M$ declares a member $m_M$ which is also named $n$
55105515
\commentary{(note that $m_M$ is also declared in $L_M$)}.
55115516
In this case a compile-time error occurs.
55125517

0 commit comments

Comments
 (0)