Oleg Kobchenko wrote:
> Unless demonstrated otherwise, there is no such thing if
> the tacit expression is a verb, Name has been undefined or is a verb
> and fix (f.) is not used. All of which is true for those example.

I stand corrected.

On the other hand...  there's something going on here that has
to do with the way a verb name is resolved.

Usually, a name is resolved to either

(a) a local value in the current execution context or
(b) a direct locative or
(c) its value as determined by one of the above two rules

Execution contexts come from explicit definition and also
exist while a script is executing.

The problem with finding the name of the verb using the
expression
   v A
is that 5!:5 will resolve the name using (c), only falling
back to (b) if the name is defined in some locale other than
the current locale.

However, as you point out, different rules are used for 
expressions, which implies that using the name in a well
known expression could be used to get the name of the verb
to the adjective, while leaving the locale reference intact
so that the verb can be executed:

    (v ]) A  NB. dyad
    [EMAIL PROTECTED] A    NB. monad

For example:

   A_t_=:1 :0
name=.5!:5<'u.'
value=.u. y.
name;value
)
   v=: +:
   [EMAIL PROTECTED] A_t_ 3
+---+-+
|[EMAIL PROTECTED]|6|
+---+-+

However, this might also be thought of as exposing a
bug in 5!:5 -- when a name is defined in some other
locale, 5!:5 loses track of this information.

   A_t_=:1 :0
name=.5!:5<'u.'
value=.".name,":y.
name;value
)
   [EMAIL PROTECTED] A_t_ 3
|value error:y.
|   value=.".name,":    y.

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

Reply via email to