Just wondering why

        isgerund=: 3 : 0 :: 0
                y@.]
                1
        )

isn't an acceptable test for “gerundality”?

I also kind of agree with Bill, in the sense that J doesn’t seem to have been
designed from the ground up (or halfway up for that matter) to facilitate
programmatically building code / functions with gerunds. Gerunds seem
to have been designed more for @. conditionals and sending multiple verbs
to adverbs like }., and using foreigns to manipulate them just seems kind
of “hacky” to me.

This of course doesn’t mean that writing such code is impossible;
just that doing so leads to highly incomprehensible code (at least to the 
casual J
programmer; sorry, but I haven’t the faintest idea how most of your wicked tacit
wizardry works Pepe!) There are other languages such as Lisp whose lists and
highly regular syntax are designed specifically around that, or Haskell where
currying means that any function taking more than one argument is a higher-
order function returning another function; and J and APL’s syntaxes have other
fortes, notably terseness and remarkable idiomatic qualities.

I feel that a big part of this comes from being able to write code that does a 
lot
in a small space, with few parentheses, and with relatively simple parsing 
rules;
and without the current noun-verb-adverb hierarchy, one of those three qualities
would be lessened.

Adding first-class verbs would kind of blur that hierarchy, and while they are 
interesting
to have in unofficial interpreters I believe that the official interpreter 
should stay
lean, efficient, relatively consistent, but especially practical to use for the 
average
J programmer. So the question is wether the “generality” or “completeness” added
by first-class verbs is worth the losses in other areas.

All that to say that I agree with Bill that gerunds as they are now have been 
designed
to be created with the tie conjunction, and while they are not perfect, they are
an acceptable compromise.

Louis

> On 03 Aug 2017, at 19:31, Bill <[email protected]> wrote:
> 
> From my understanding, the reference shows the atomic representation of 
> gerund. It does not advocate this a way to construct a gerund. moreover it is 
> "foreign" conjunction.
> 
> numbers can be converted from strings using foreign conjunction but it 
> doesn't mean J encourages writing numbers using this method.
> 
> IMO foreign conjunction is not a part of J core.
> 
> 
> Sent from my iPhone
> 
> On 4 Aug, 2017, at 5:33 AM, Jose Mario Quintana 
> <[email protected]> wrote:
> 
>> "
>> In J dictionary, only tie conjunction
>> on verbs was mentioned to produce a gerund.
>> "
>> 
>> I am afraid you might not be the only one who has reached such conclusion.
>> Nevertheless, in my opinion, it is a misconception that a gerund can only
>> be a list (of atomic representations) of verbs.  Why?  See [0] in the
>> context of [1].
>> 
>> [0] Atomic
>>   http://www.jsoftware.com/help/dictionary/dx005.htm#1
>> 
>> [1] [Jprogramming] how to test for a gerund  Roger Hui
>>   http://www.jsoftware.com/pipermail/programming/2010-April/019178.html
>> 
>> Mind you  gerundYN  is not bulletproof.
>> 
>> 
>> On Thu, Aug 3, 2017 at 5:46 AM, bill lam <[email protected]> wrote:
>> 
>>> I am thinking of the opposite. In J dictionary, only tie conjunction
>>> on verbs was mentioned to produce a gerund. Boxed verbs had not been
>>> mentioned. Atomic representation of boxed verbs looks like that of
>>> gerund and therefore can work as gerund. IMO this is a backdoor
>>> provided by J implementation.
>>> 
>>> Metadata could be attached to "real" gerunds that have ancestors which
>>> were  results of verb`verb. All other nouns without this DNA would be
>>> regarded as non-gerund.
>>> 
>>> Just my 2 cents.
>>> 
>>> On Thu, Aug 3, 2017 at 3:57 PM, Marshall Lochbaum <[email protected]>
>>> wrote:
>>>> Can I just point out that it's not too late to add some (documented) way
>>>> to box verbs/adverbs/conjunctions? These could be treated as gerunds by
>>>> everything that currently uses gerunds, and the interpreter can just
>>>> throw an error if anything attempts to actually unbox them. They are
>>>> much harder to confuse than the current gerunds, and will have far
>>>> better performance.
>>>> 
>>>> This sounds like a radical divergence from the way J works now, but I
>>>> don't think it is in practice. Programmers would use some new
>>>> conjunction to replace (`), and provided they don't inspect the
>>>> structure of gerunds nothing else changes. I suppose there would need to
>>>> be a way to check what class of object a box contains, because unboxing
>>>> to check the type is not allowed. Gerunds would remain useful for
>>>> programmers who want to inspect functions or build them from scratch,
>>>> but would otherwise become obselete.
>>>> 
>>>> Marshall
>> ----------------------------------------------------------------------
>> For information about J forums see http://www.jsoftware.com/forums.htm
> ----------------------------------------------------------------------
> For information about J forums see http://www.jsoftware.com/forums.htm

----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to