[GHC] #7229: Detecting if a process was killed by a signal is impossible

GHC ghc-devs at haskell.org
Wed Nov 13 18:00:05 UTC 2013


#7229: Detecting if a process was killed by a signal is impossible
--------------------------------------+------------------------------------
        Reporter:  benmachine         |            Owner:
            Type:  bug                |           Status:  new
        Priority:  highest            |        Milestone:  7.8.1
       Component:  libraries/process  |          Version:
      Resolution:                     |         Keywords:
Operating System:  Unknown/Multiple   |     Architecture:  Unknown/Multiple
 Type of failure:  None/Unknown       |       Difficulty:  Unknown
       Test Case:                     |       Blocked By:
        Blocking:                     |  Related Tickets:
--------------------------------------+------------------------------------

Comment (by duncan):

 @andersk just to play devil's advocate for a moment: why not use negative
 encoding for signals, and just ignore the core dump bit? It gives an
 encoding that is very simple to use and very few people care about core
 dumps (and if they do, they can use the unix package).

 `-n` is a lot easier than {{{(n .&. 0x7f00) `shiftR` 8}}}. Indeed people
 are likely to do it wrong and just use {{{n `shiftR` 8}}} in which case
 they'll get tripped up whenever there is a core dump (which is platform
 configuration specific).

--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/7229#comment:40>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler


More information about the ghc-tickets mailing list