From 541f7c1421941ac8ed80be095e6489ff2f38b5a0 Mon Sep 17 00:00:00 2001 From: Neil Brown Date: Tue, 20 Jan 2009 17:25:19 +0000 Subject: [PATCH] Turned the Chan type into a Chan type for full channels and a ChanEnd type for the directed ends This is the first patch in the series of many that implement this change throughout Tock. Fixes #70. --- data/AST.hs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/data/AST.hs b/data/AST.hs index ad400e0..42111b5 100644 --- a/data/AST.hs +++ b/data/AST.hs @@ -78,8 +78,6 @@ data NameSource data Direction = DirInput -- ^ The input end. | DirOutput -- ^ The output end. - | DirUnknown -- ^ Either direction; either this is a whole channel, - -- or its direction is to be figured out later. deriving (Show, Eq, Typeable, Data) -- | Attributes of the type of a channel. @@ -126,7 +124,9 @@ data Type = -- | A user-defined protocol. | UserProtocol Name -- | A channel of the specified type. - | Chan Direction ChanAttributes Type + | Chan ChanAttributes Type + -- | A channel end of the specified type. + | ChanEnd Direction ChanAttributes Type -- | A counted input or output. -- The first type is that of the count; the second is that of the array. -- (For example, @INT::[]BYTE@ would be @A.Counted A.Int (A.Array ...)@).