Contents

ieval

ieval is a program to interactively evaluate icon expressions. Input is read from the terminal until end-of-file (control-D) is entered. Each expression has its results sequence evaluated and printed (although see the !q option below). Variables may be assigned to, and they are stored in a local environment, which may be printed by entering !env. To link with library packages, use the -i command line option. Packages can't be imported interactively.

An example session

$ ieval -i lang,graphics
> &version
"Object Icon Version 2.6.  Mon Aug 29 11:57:11 BST 2011"
> upto('aeiou', "The quick brown fox")
3
6
7
13
18
> w := Window()
object graphics.Window#1(ptr=136611152)
> w.close()
object graphics.Window#1(ptr=0)
> ^D
$

Input of an expression over several lines can be achieved by ending a line with a backslash character. The prompt changes to >> and the next line is concatenated to the previous one.

Command line options

ieval accepts the following command-line options :-

Remaining arguments specify files which are processed before command line input commences. They should contain valid expressions (which may be compound expressions).

Useful built-in expressions

Keyboard shortcuts

Unless ieval is started with the -s option, it keeps a history of entered expressions, and uses the following keyboard shortcuts :-

Contents