Warning

You're browsing the old v2.x documentation. This version is no longer maintained. Click here to go the v3.x documentation.

This is an old revision of the document!


ALIASFN

Since version 2.2

Syntax:

aliasfn <const int address>, "<function name>"

The ALIASFN directive registers a new function alias in order to make it possible to call a user function without the USR keyword. This directive is mainly used in extensions.

The function name must be a valid identifier i. e. it starts with a alpha or underscore and contains alpahumeric chars or underscores only. It may be appended with a sigil - any of these characters: !#%$ indicating that the function alias refers to a function that returns a specific type. The default is # (integer).

Example:

aliasfn $c000, "myfunc"

rem -- Assuming that a machine code function resides at address $C000,
rem -- the following two function calls are identical:

x = usr($c000, arg1, arg2)
y = myfunc(arg1, arg2)