Comments
Loading Dream Comments...
You must be logged in to write a comment - Log In
::SHE+ILA:: segments and modules can be edited and debugged with the PENGE editor (Program Environment NONOP Generic Editor). Using the NONOP operator "&" yields a reference to a function rather than actively calling the function, and this allows the function (or other data structure, such as a buffer or an array) to be breakpointed or modified at run-time, or values to be watched and logged. Example : User types "Penge (&myfunction)"
[1] 0 ::> i;
[2] {* i.lt.10 : // begin loop (while i is less than 10);
[3] TTY << ++i;
[4] TTY << " squared is ";
[5] TTY << i*i;
[6] TTY << CRLF;
[7] *} // end loop;
User then types : [5.5] TTY << " and cubed is " << i*i*i << CRLF;
The added line updates the function "myfunction". Multidimensional arrays (including ragged arrays) can also be edited in this way, for example : Penge (3 3 .ro. .io. 9 ::> X)
[1] 1 2 3
[2] 4 5 6
[3] 7 8 9
User then types [2] 6 5 4
and exits the editor and then type X. The system then outputs (1 2 3)(6 5 4)(7 8 9).