[Haskell-cafe] a really juvenile question .. hehehehe ;^)

Galchin, Vasili vigalchin at gmail.com
Mon Oct 6 01:35:38 EDT 2008


Hello,

   I am reading some extant Haskell code that uses Posix signals.... I am
confused by the motivation of the following ...

type Signal<http://hackage.haskell.org/packages/archive/unix/2.3.0.0/doc/html/System-Posix-Signals.html#t%3ASignal>=
CInt<http://hackage.haskell.org/packages/archive/base/3.0.1.0/doc/html/Foreign-C-Types.html#t%3ACInt>
nullSignal<http://hackage.haskell.org/packages/archive/unix/2.3.0.0/doc/html/System-Posix-Signals.html#v%3AnullSignal>::
Signal<http://hackage.haskell.org/packages/archive/unix/2.3.0.0/doc/html/System-Posix-Signals.html#t%3ASignal>
internalAbort<http://hackage.haskell.org/packages/archive/unix/2.3.0.0/doc/html/System-Posix-Signals.html#v%3AinternalAbort>::
Signal<http://hackage.haskell.org/packages/archive/unix/2.3.0.0/doc/html/System-Posix-Signals.html#t%3ASignal>
sigABRT<http://hackage.haskell.org/packages/archive/unix/2.3.0.0/doc/html/System-Posix-Signals.html#v%3AsigABRT>::
CInt<http://hackage.haskell.org/packages/archive/base/3.0.1.0/doc/html/Foreign-C-Types.html#t%3ACInt>
realTimeAlarm<http://hackage.haskell.org/packages/archive/unix/2.3.0.0/doc/html/System-Posix-Signals.html#v%3ArealTimeAlarm>::
Signal<http://hackage.haskell.org/packages/archive/unix/2.3.0.0/doc/html/System-Posix-Signals.html#t%3ASignal>
sigALRM<http://hackage.haskell.org/packages/archive/unix/2.3.0.0/doc/html/System-Posix-Signals.html#v%3AsigALRM>::
CInt<http://hackage.haskell.org/packages/archive/base/3.0.1.0/doc/html/Foreign-C-Types.html#t%3ACInt>
busError<http://hackage.haskell.org/packages/archive/unix/2.3.0.0/doc/html/System-Posix-Signals.html#v%3AbusError>::
Signal<http://hackage.haskell.org/packages/archive/unix/2.3.0.0/doc/html/System-Posix-Signals.html#t%3ASignal>
sigBUS<http://hackage.haskell.org/packages/archive/unix/2.3.0.0/doc/html/System-Posix-Signals.html#v%3AsigBUS>::
CInt<http://hackage.haskell.org/packages/archive/base/3.0.1.0/doc/html/Foreign-C-Types.html#t%3ACInt>

OK .. "type" is really just a synomym and doesn't invoke type checking like
"data" type declarations do .. so why don't we have all the "CInts"
substituted by "Signal"? I.e. what did I miss?

Thanks, Vasili
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.haskell.org/pipermail/haskell-cafe/attachments/20081006/8a4cea9f/attachment.htm


More information about the Haskell-Cafe mailing list