Author: larry
Date: Sat May 19 09:45:24 2007
New Revision: 14395

Modified:
   doc/trunk/design/syn/S02.pod

Log:
Clarify type semantics of sigil bindability, requested by dduncan++.


Modified: doc/trunk/design/syn/S02.pod
==============================================================================
--- doc/trunk/design/syn/S02.pod        (original)
+++ doc/trunk/design/syn/S02.pod        Sat May 19 09:45:24 2007
@@ -12,9 +12,9 @@
 
   Maintainer: Larry Wall <[EMAIL PROTECTED]>
   Date: 10 Aug 2004
-  Last Modified: 18 May 2007
+  Last Modified: 19 May 2007
   Number: 2
-  Version: 104
+  Version: 105
 
 This document summarizes Apocalypse 2, which covers small-scale
 lexical items and typological issues.  (These Synopses also contain
@@ -1080,6 +1080,20 @@
 
 =item *
 
+Sigils indicate overall interface, not the exact type of the bound
+object.  Hence, C<@x> may be bound to an object of the C<Array>
+class, but it may also be bound to any object that does the C<Array>
+role, such as a C<List>, C<Seq>, C<Range>, C<Set>, C<Bag>, C<Buf>,
+C<Capture>, and so on.  Likewise, C<%x> may be bound to a C<Pair>,
+C<Mapping>, C<Set>, C<Bag>, C<KeyHash>, C<Capture>, and so on.
+And C<&x> may be bound to any kind of C<Block> or C<Routine>.
+The implicit container type is checked at binding time.  If you wish
+to bind an object that doesn't yet do the appropriate role, you must
+either stick with the generic C<$> sigil, or mix in the appropriate
+role before binding to a more specific sigil.
+
+=item *
+
 Unlike in PerlĀ 5, you may no longer put whitespace between a sigil
 and its following name or construct.
 

Reply via email to