Re: [Bug-apl] String element of general array

2014-05-08 Thread Elias Mårtenson
And of course, it can be made generic using ¨: * x ← 'foo' 'bar' 'this' 'is' 'a' 'list' 'of' 'strings'* * x ≡¨ ⊂'bar'* 0 1 0 0 0 0 0 0 Regards, Elias On 9 May 2014 13:35, David B. Lamkins wrote: > The outer product approach is APL 1. > > In APL 2, you can enclose the search term and

Re: [Bug-apl] String element of general array

2014-05-08 Thread David B. Lamkins
The outer product approach is APL 1. In APL 2, you can enclose the search term and test for membership in the list: ll←'abd' 'defgh' 'ij' 'klm' ll∊⊂'ij' 0 0 1 0 ll∊⊂'foo' 0 0 0 0 On Thu, 2014-05-08 at 22:56 -0500, Blake McBride wrote: > Forgive the question, but my experience

Re: [Bug-apl] Emacs mode: can't create a function with no lines

2014-05-08 Thread Elias Mårtenson
Yes, I've been told that this happens. I just can't seem to reproduce it though. Can you confirm that it doesn't happen if you move the cursor prior to pressing C-c C-c? What version of Emacs are you using? Regards, Elias On 9 May 2014 11:59, Blake McBride wrote: > From within emacs mode I do

Re: [Bug-apl] String element of general array

2014-05-08 Thread Elias Mårtenson
It's easier than that. Your solution is: *∨/ (⊂'bar') ⍷ x* This is because X⍷Y returns a list of the elements of X that matches Y. Then ∨/ is just a reduction of that. Regards, Elias On 9 May 2014 11:56, Blake McBride wrote: > Forgive the question, but my experience is only with the or

[Bug-apl] )ERASE should complain if not found?

2014-05-08 Thread Blake McBride
I'm not sure of this but - if you try to )ERASE something that isn't there, shouldn't it display a not found message on the ones not found? The problem is, if you erase something and mistype it, there is no message. You have no idea you didn't erase it. I don't remember what other APL's did. Pe

[Bug-apl] )COPY bad display

2014-05-08 Thread Blake McBride
When attempting to copy only a subset of functions from a WS I get all sorts of incorrect output. For example: )load Devices SAVED 2014-5-5 0:39:1 (GMT-5) )copy Devices Pic NOT COPIED: CAL NOT COPIED: CS NOT COPIED: Cms NOT COPIED: Delim NOT COPIED: Dn NOT COPIED: Dtfmt NOT COPIED:

[Bug-apl] )SAVE should show WSID

2014-05-08 Thread Blake McBride
Greetings, I believe the )SAVE command should display the name of the workspace after the date and time. I am looking at the Gilman and Rose APL2 book and that's the way they show it. (In addition to my memory.) Thanks. Blake

[Bug-apl] Emacs mode: can't create a function with no lines

2014-05-08 Thread Blake McBride
>From within emacs mode I do: ∇xx and then save without adding any lines, emacs gives: Unexpected error: Thanks! Blake

[Bug-apl] String element of general array

2014-05-08 Thread Blake McBride
Forgive the question, but my experience is only with the original APL and not APL2. I have a (general array) vector. Each element is a string vector. For example: x←'abcd' 'efg' 'hijkl' Now, if I have: y←'hijkl' z←'hhh' How can I tell if y is in x? How can I tell if z is in x? I can eas

[Bug-apl] gettext() and ⎕NLT removed

2014-05-08 Thread Juergen Sauermann
Hi, after having more and more problems with it, I decided to remove gettext() and ⎕NLT from GNU APL. SVN 257. /// Jürgen

[Bug-apl] APL Package Manager preview

2014-05-08 Thread David B. Lamkins
The APL Package Manager has, over the past week and a half or so, matured to a point where I believe that it's now suitable for a first look by interested parties. The external API will evolve, so please don't use the package manager with the expectation that I won't soon negate the fruits of your

Re: [Bug-apl] native function lib_file_io reload not working

2014-05-08 Thread Peter Teeson
Hi Jürgen: Never noticed the link before but I just printed it out for thoughtful reading. respect…. Peter On 2014-05-08, at 10:25 AM, Juergen Sauermann wrote: > Hi, > > I have written a proposal earlier but haven't received any comments so far. > > The document is available here: > http://w

Re: [Bug-apl] native function lib_file_io reload not working

2014-05-08 Thread David B. Lamkins
I missed the link the first time around, I think. I'll take a look at this tonight or tomorrow. Thank you. On Thu, 2014-05-08 at 16:25 +0200, Juergen Sauermann wrote: > Hi, > > I have written a proposal earlier but haven't received any comments so > far. > > The document is available here: > h

Re: [Bug-apl] native function lib_file_io reload not working

2014-05-08 Thread David B. Lamkins
On Thu, 2014-05-08 at 14:56 +0200, Juergen Sauermann wrote: > 'lib_file_io' ⎕fx 'pkg⍙fileio' Thank you.

Re: [Bug-apl] native function lib_file_io reload not working

2014-05-08 Thread Juergen Sauermann
Hi, I have written a proposal earlier but haven't received any comments so far. The document is available here: http://www.gnu.org/software/apl/Library-Guidelines.html so that we don't need to scan the bug-apl mail archive. According to it package⍙ is the prefix for meta information of a pack

Re: [Bug-apl] Preventing display of too large arrays

2014-05-08 Thread Juergen Sauermann
Hi Elias, I have added an item in ⎕SYL that cuts down APL value when printed as non-committed value (i.e. as statement result). SVN 253. /// Jürgen On 04/30/2014 05:30 PM, Elias Mårtenson wrote: Are you saying that this limit exists, or that it's something that would have to be implemented?

Re: [Bug-apl] Bug: GNU APL does not call start_input after a )LOAD

2014-05-08 Thread Elias Mårtenson
OK, thanks for the hints. I've spent some time looking at this issue and I now have an idea what is happening. When you issue )LOAD, the native library becomes loaded again, even though it's already loaded. There are two issues with this: First and foremost, after the )LOAD the version of libemac

Re: [Bug-apl] native function lib_file_io reload not working

2014-05-08 Thread Elias Mårtenson
Is this the standard system we should abide by? To separate the module and function name with ⍙? Are we using ∆ for public functions and ⍙ for private ones? So far I've used ∆∆ (two deltas) as separator for internal functions. Regards, Elias On 8 May 2014 20:56, Juergen Sauermann wrote: > Hi Da

Re: [Bug-apl] native function lib_file_io reload not working

2014-05-08 Thread Juergen Sauermann
Hi David, thanks, fixed in SVN 252. /// Jürgen On 05/07/2014 08:53 PM, David B. Lamkins wrote: 'lib_file_io' ⎕fx 'pkg⍙fileio' pkg⍙fileio )erase pkg⍙fileio 'lib_file_io' ⎕fx 'pkg⍙fileio' pkg⍙fileio pkg⍙fileio⍬ VALUE ERROR pkg⍙fileio⍬ ^

Re: [Bug-apl] Bug: GNU APL does not call start_input after a )LOAD

2014-05-08 Thread Juergen Sauermann
Hi, could you please print the value of start_input just before line 223 in Input.cc like: *I**nput::get_user_line(const UCS_string * prompt) { Q(start_input) if (start_input) (*start_input)(); ...* On my machine it looks OK (even if I don't set it): * This program is free softwar