Show
Ignore:
Timestamp:
07.01.2009 14:48:37 (11 months ago)
Author:
csliam
Message:

Static analysis of CspCASL now adds channel names and process names to the collected symbols (stored in the CASL signature)

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/CspCASL/StatAnaCSP.hs

    r11224 r11231  
    2929import CASL.Overload (minExpFORMULA, oneExpTerm) 
    3030import CASL.Sign 
    31 import CASL.Morphism (RawSymbol) 
    3231import CASL.StaticAna (allOpIds, allPredIds) 
    3332import Common.AS_Annotation 
     
    4544import CspCASL.Print_CspCASL () 
    4645import CspCASL.SignCSP 
     46import CspCASL.Morphism(makeChannelNameSymbol, makeProcNameSymbol) 
    4747 
    4848import qualified Data.Set as Set 
     
    121121              return m 
    122122      else case Map.lookup chanName m of 
    123              Nothing -> return (Map.insert chanName s m) -- insert new. 
     123             Nothing -> 
     124                 -- Add the channel name as a symbol to the list of 
     125                 -- newly defined symbols - which is stored in the CASL 
     126                 -- signature 
     127                 do addSymbol (makeChannelNameSymbol chanName) 
     128                    return (Map.insert chanName s m) -- insert new. 
    124129             Just e -> 
    125130               if e == s 
     
    160165                alpha <- Monad.foldM (anaCommType sig) S.empty commTypes 
    161166                let profile = (ProcProfile argSorts alpha) 
     167                -- Add the process name as a symbol to the list of 
     168                -- newly defined symbols - which is stored in the CASL 
     169                -- signature 
     170                addSymbol (makeProcNameSymbol name) 
    162171                return (Map.insert name profile oldProcDecls) 
    163172    vds <- gets envDiags