Map
Index
Random
Help
Topics
th

Topic: control returning functions and expressions

topics > computer science > programming > Group: program control



Group:
expression evaluation
Topic:
conditional expression
Topic:
conditional statement
Topic:
exception handling by termination
Topic:
exception handling by unique value
Topic:
failure returning functions and expressions

Summary

Most language systems include a boolean data type which can be used as a guard. Some languages have the concept of function failure and success which may be used for control purposes. Failure of a function is often seen as signaling an exception. With most, the control returning is optional, but some systems see all functions as returning control (e.g., SNOBOL); others see all values as applicable for control (usually a null response is false while all others are true). One language, SL/5, sees all functions returning a control value and a result value. Functions may also return control, yet have null values when combined in expressions; or they may return control if false and a value if true. In data flow languages, functions may indicate the presence of data or other logical and comparative operations. Control values in all languages may be arguments to other functions. (cbb 5/80)
Subtopic: signal as return value, success/failure up

Quote: an SL5 expression returns a value and a signal; the signal is an unsigned integer used for control purposes, e.g., true/false [»hansDR5_1978]
Quote: the result of an SL5 variable reference is where it resides and a true signal [»hansDR5_1978a]
Quote: in Icon, tab (10|5) == tab(10)|tab(5) because a failure of tab(10) invokes the alternative value [»grisRE4_1980]
QuoteRef: farbDJ1_1964 ;;26 gotos by /(label) f(label) s(label) for always, failure, success
QuoteRef: martMJ_1974 ;;668 an expression group of statements can return succeed, fail or value for a case control statement

Subtopic: control expression up

Quote: del control primitive for APL; e.g., x.del.1000 repeats x 1000 times
[»vanbFH12_2001]

Related Topics up

Group: expression evaluation   (5 topics, 97 quotes)
Topic: conditional expression (11 items)
Topic: conditional statement (8 items)
Topic: exception handling by termination (16 items)
Topic: exception handling by unique value (8 items)
Topic: failure returning functions and expressions
(24 items)

Updated barberCB 4/04
Copyright © 2002-2008 by C. Bradford Barber. All rights reserved.
Thesa is a trademark of C. Bradford Barber.