diff --git a/docs/source/programming.rst b/docs/source/programming.rst index b7d6fe278..e2f80ef64 100644 --- a/docs/source/programming.rst +++ b/docs/source/programming.rst @@ -150,7 +150,8 @@ you from having to type the fully scoped name everytime you need to access that Aliases can be created in any scope except at the module level. You can create and use an alias with the ``alias`` statement like so:: - alias prn = txt.print_ub + alias score = cx16.r7L ; 'name' the virtual register + alias prn = txt.print_ub ; shorter name for a subroutine elsewhere ... prn(score) diff --git a/docs/source/syntaxreference.rst b/docs/source/syntaxreference.rst index bc47c1d5f..f3f92abd9 100644 --- a/docs/source/syntaxreference.rst +++ b/docs/source/syntaxreference.rst @@ -832,6 +832,8 @@ It is not possible to use floating point arguments or return values in an asmsub ``cx16.r0`` .. ``cx16.r15`` (these are memory mapped uword values), ``cx16.r0s`` .. ``cx16.r15s`` (these are memory mapped word values), and ``L`` / ``H`` variants are also available to directly access the low and high bytes of these. + You can use them directly but their name isn't very descriptive, so it may be useful to define + an alias for them when using them regularly. Expressions