Next: , Previous: , Up: platform   [Index]


3.3 Hosting platform utilities

The library (vicare platform utilities) defines helper functions to deal with platform specific issues. The following bindings are exported by the library (vicare platform utilities).

Syntax: posix-signal->symbol code

Given an integer representing an interprocess POSIX signal code, return the corresponding symbol; if code is not recognised as POSIX signal code: return #f.

(import (rnrs)
  (vicare platform constants)
  (vicare platform utilities))

(posix-signal->symbol SIGTERM)            ⇒ SIGTERM
(posix-signal->symbol (greatest-fixnum))  ⇒ #f
Function: errno-code->symbol code

Given a fixnum representing an encoded errno value, return the corresponding symbol; if code is not recognised as encoded errno value: return #f.

(import (rnrs)
  (vicare platform constants)
  (vicare platform utilities))

(errno-code->symbol EINVAL)             ⇒ EINVAL
(errno-code->symbol (greatest-fixnum))  ⇒ #f