[r6rs-discuss] Script exit code

From: Marcin 'Qrczak' Kowalczyk <qrczak>
Date: Mon Sep 18 14:56:44 2006

7.1.2.

I don't like the way scripts specify the exit code, by taking the
value of the last expression.

The exit code is rarely interesting. When it's different than the
default, often this is determined at some other place than the end of
the script: namely in the place which has detected a problem and wants
to abort the script. It's easy to forget the exit code.

I would prefer to have a standard condition which is intended to exit
the program, and which carries the exit code. A standard function with
an optional exit code parameter just raises that condition.

-- 
   __("<         Marcin Kowalczyk
   \__/       qrczak_at_knm.org.pl
    ^^     http://qrnik.knm.org.pl/~qrczak/
Received on Mon Sep 18 2006 - 14:56:36 UTC

This archive was generated by hypermail 2.3.0 : Wed Oct 23 2024 - 09:15:01 UTC