Changeset 36402 in project


Ignore:
Timestamp:
08/25/18 12:44:38 (3 months ago)
Author:
kooda
Message:

Port the args-example.scm file to CHICKEN 5

File:
1 edited

Legend:

Unmodified
Added
Removed
  • release/5/args/trunk/args-examples.scm

    r32428 r36402  
    11(module main ()
    22
    3   (import scheme (rename chicken (program-name $0)))
    4   (require-library extras ports data-structures)
    5   (import (only extras printf))
    6   (import (only ports with-output-to-port))
    7   (import (only data-structures alist-ref))
    8   (use args)
     3  (import
     4    scheme
     5    (chicken base)
     6    (chicken format)
     7    (chicken port)
     8    (chicken process-context)
     9    args)
     10
    911
    1012;;; Some handy shortcuts for below
     
    3133  (with-output-to-port (current-error-port)
    3234    (lambda ()
    33       (print "Usage: " ($0) " [options...] [files...]")
     35      (print "Usage: " (program-name) " [options...] [files...]")
    3436      (newline)
    3537      (print (args:usage opts))
Note: See TracChangeset for help on using the changeset viewer.