Changeset 31307 in project


Ignore:
Timestamp:
08/29/14 18:16:21 (5 years ago)
Author:
Kon Lovett
Message:

rel 1.0.4

File:
1 edited

Legend:

Unmodified
Added
Removed
  • wiki/eggref/4/condition-utils

    r28426 r31307  
    1313predicates, and accessors.
    1414
    15 ==== Argument Conventions
     15=== Argument Conventions
    1616
    1717{{LOC}} is a {{symbol}}, or {{#f}}.
     
    2020
    2121{{ARGS}} is a {{list}}, or {{#f}}.
     22
     23{{CHN}} is the result of {{(get-call-chain)}}, or {{#f}}.
    2224
    2325{{COND}} is a:
     
    3133{{PROP}} is a {{symbol}}.
    3234
    33 ==== make-exn-condition
     35=== make-exn-condition
    3436
    35 <procedure>(make-exn-condition [LOC [MSG [ARGS]]]) => property-condition</procedure>
     37<procedure>(make-exn-condition [LOC [MSG [ARGS [CHN]]]]) => property-condition</procedure>
    3638
    3739Returns an {{exn}} {{property-condition}} with optional {{location}},
    38 {{message}} and {{arguments}} property values.
     40{{arguments}}, and {{call-chain}} property values.
    3941
    4042Defaults:
    4143
    42 ; {{LOC}} : {{#f}}
    43 ; {{MSG}} : {{""}}
    44 ; {{ARGS}} : {{'()}}
     44; {{LOC}} : missing
     45; {{MSG}} : {{"unknown"}}
     46; {{ARGS}} : missing
     47; {{CHN}} : missing
    4548
    46 Will always include {{location}}, {{message}} and {{arguments}} properties in
    47 the {{property-condition}}.
     49Will always include {{message}} property in the {{property-condition}}.
    4850
    49 ==== make-exn-condition+
     51=== make-exn-condition+
    5052
    51 <procedure>(make-exn-condition+ LOC MSG ARGS [COND...]) => property-condition</procedure>
     53<procedure>(make-exn-condition+ LOC MSG ARGS [CHN] [COND...]) => property-condition</procedure>
    5254
    5355Returns a {{composite-condition}} {{exn COND...}}.
    5456
    5557When one-of {{LOC}}, {{MSG}}, or {{ARGS}} is without a useful value in the
    56 error context be sure to use {{#f}} as the actual argument.
     58error context use {{#f}} as the actual argument. The optional {{CHN}} argument
     59is detected by structure.
    5760
    58 ==== make-condition+
     61When {{MSG}} is {{#f}} the value {{"unknown"}} is used.
     62
     63=== make-condition+
    5964
    6065<procedure>(make-condition+ COND...) => property-condition</procedure>
     
    6267Returns a {{composite-condition}} {{COND...}}.
    6368
    64 ==== condition-predicate*
     69=== condition-predicate*
    6570
    6671<procedure>(condition-predicate* KIND) => (procedure (*) boolean)</procedure>
     
    6873Returns a "memioized" {{condition-predicate}} for {{KIND}}.
    6974
    70 ==== make-condition-predicate
     75=== make-condition-predicate
    7176
    7277<macro>(make-condition-predicate KIND...) => (procedure (*) boolean)</macro>
     
    7479Returns a {{condition-predicate}} for {{KIND...}}.
    7580
    76 ==== condition-property-accessor*
     81=== condition-property-accessor*
    7782
    7883<procedure>(condition-property-accessor* KIND PROP [DEFAULT]) => (procedure (*) boolean)</procedure>
     
    8085Returns a "memioized" {{condition-property-accessor}} for {{KIND}}.
    8186
    82 ==== make-condition-property-accessor
     87=== make-condition-property-accessor
    8388
    8489<macro>(make-condition-property-accessor KIND PROP [DEFAULT]) => (procedure (*) boolean)</macro>
    8590
    8691Returns a {{condition-property-accessor}} for {{KIND PROP}}.
     92
     93=== condition-irritants
     94
     95<procedure>(condition-irritants EXN) => list</procedure>
     96
     97Returns a property list of the condition properties for the condition {{EXN}}.
     98The properties are without associated condition information.
    8799
    88100
     
    101113== Version history
    102114
     115; 1.0.4 : default exn msg
     116; 1.0.3 : added call-chain argument & standard conditions
    103117; 1.0.2 : Fix for ticket #630
    104118; 1.0.1 :
     
    108122== License
    109123
    110 Copyright (C) 2010 Kon Lovett.  All rights reserved.
     124Copyright (C) 2009-2014 Kon Lovett.  All rights reserved.
    111125
    112126Permission is hereby granted, free of charge, to any person obtaining a
Note: See TracChangeset for help on using the changeset viewer.