moduleCalls :: SGraph -> Int
moduleCalls cg = length es
    where
    g = graph cg
    es = filter isInterModuleCall $ edges g
    isInterModuleCall (x,y) = case (lab g x,lab g y) of
        (Just x',Just y') -> inModule x' /= inModule y'
        otherwise -> False
moduleCalls :: SGraph -> Int
moduleCalls cg = length es
    where
    g = graph cg
    es = filter isInterModuleCall $ edges g
    isInterModuleCall (x,y) = case (lab g x,lab g y) of
        (Just x',Just y') -> inModule x' /= inModule y'
        otherwise -> False
moduleCalls cg = length es
    where
    g = graph cg
    es = filter isInterModuleCall $ edges g
    isInterModuleCall (x,y) = case (lab g x,lab g y) of
        (Just x',Just y') -> inModule x' /= inModule y'
        otherwise -> False