Joe Bogner <[email protected]> writes: Hi Joe,
> I've used fun? to determine if an argument had the proper form of > something that was executable or if it was data. It may not work in > all cases, but it was sufficient for my use case. As Alex mentioned, > it won't let you know whether it's actually executable or not. I think > of it as having the potential to be executable. 'fun? would be another possibility, but 'pair is a little bit more tolerant (returns non-NIL in more cases), and since I apply it on Emacs Lisp (and not PicoLisp) expressions, this tolerance seems to be a good thing. But thanks for the tip anyway! > On Mon, Jul 1, 2013 at 4:50 AM, Thorsten Jolitz > <[email protected]> wrote: > > dexen deVries > <[email protected]> writes: > > > > On Monday 01 of July 2013 07:39:49 you wrote: > >> Hi Thorsten, > >> > >> > I wonder if there is a way in PicoLisp to check if some function > >> > argument is a SEXP, i.e. if something like a function 'sexp? exists > that > >> > returns T if the argument is a SEXP. > > > > > > how about (pair 'any) ? basically the opposite of (atom 'any) > > > thats probably what I was looking for, thanks, besides the fact that > Alex is of course right about the difficulties with doing these kind of > tests in a dynamic environment. > > > > -- > cheers, > Thorsten > > -- > UNSUBSCRIBE: mailto:[email protected]?subject=Unsubscribe > > > -- cheers, Thorsten -- UNSUBSCRIBE: mailto:[email protected]?subject=Unsubscribe
