All this makes some sort of sense if you pay attention to the "parts of speech" aspect in the LC dictionary entries. "The foundfield" is a function, and so it's not surprising that the parser objects to something like "put random(99) into the foundfield." If you look at the entry for "the selection" it's listed as a keyword, and there is a specific note that although it's implemented internally as a function it can be used as a referenced container.The engine appears to handle "the selection" quite differently, performing an extra evaluation when the term is used as a noun (the object of the preposition "into"). I wonder why Scott Raney made this exception? But it's quite useful.
-- Peter Peter M. Brigham [email protected] http://home.comcast.net/~pmbrig On May 7, 2013, at 10:58 PM, J. Landman Gay wrote: > On 5/7/13 7:06 PM, [email protected] wrote: > >> When I first started with LC, one of the first things I tried was to >> see if something like the first construction above processed "like >> it should". I think I tested "the foundField". I was astonished that >> it did not. Is there is something deeply ingrained in the way this >> type (all types?) of parsers work that it can not do this? > > I'm not sure how any parser could tell if you meant the variable to be a > container or the value that's in it. "Get the clickline" is just a shortcut > for "put the clickline into it". So you have: > > put the clickline into it > put random(99) into it > > which is functionally the same as: > > put "abc" into it > put "def" into it > > What we really need is a mind-reading processor. I could have used that today. > > -- > Jacqueline Landman Gay | [email protected] > HyperActive Software | http://www.hyperactivesw.com > > _______________________________________________ > use-livecode mailing list > [email protected] > Please visit this url to subscribe, unsubscribe and manage your subscription > preferences: > http://lists.runrev.com/mailman/listinfo/use-livecode _______________________________________________ use-livecode mailing list [email protected] Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
