aqualectrix
Member
I think I don't understand what CLI's "using" command is supposed to do. I hoped it would allow me to stop typing "include <myscript.ash>" in my CLI ash commands while testing out bits and pieces of my scripts. But it doesn't seem to do so.
(I did manage to figure out how to un-use, though: clear the global preference commandLineNamespace.)
Example:
myscript.ash:
On the CLI:
Is this just not what using is supposed to do? In that case, what is it supposed to do? I await enlightenment!
(It's not a bother if that's not what it is supposed to do, obviously, but it makes me curious.)
(I did manage to figure out how to un-use, though: clear the global preference commandLineNamespace.)
Example:
myscript.ash:
Code:
int myfunc(int a)
{ return a + 1; }
On the CLI:
Code:
> ash myfunc(1)
Function 'myfunc( int )' undefined ()
Returned: void
> ash import <myscript.ash> myfunc(1);
Returned: 2
> using myscript.ash
int myfunc( int a )
Script verification complete.
> ash myfunc(1)
Function 'myfunc( int )' undefined (myscript.ash)
Returned: void
Is this just not what using is supposed to do? In that case, what is it supposed to do? I await enlightenment!
(It's not a bother if that's not what it is supposed to do, obviously, but it makes me curious.)