Contexts

Started by newdep, March 01, 2004, 01:19:18 AM

Previous topic - Next topic

newdep

Hello Lutz,



How can i display all generated namespaces under newlisp? For the GUI-TK version you have this seperated window which contains all known Contexts, in the console mode a function like (contexts) would be very nice to have..



> (contexts)

( MAIN a PERSONS testing )





Regards, Norman.
-- (define? (Cornflakes))

HPW

#1
Hello newdep,



From newLISP-tk.tcl



(filter (lambda (x) (context? (eval x))) (symbols 'MAIN))
Hans-Peter

newdep

#2
Hello HPW,



Aaaa Thanks !!! Ill have a look in the code...

Nifty function btw.. ;-)



Norman.
-- (define? (Cornflakes))

nigelbrown

#3
A variation:

(filter context? (map eval (symbols)))

newdep

#4
Thank you for the tips, because i was just looking for  way on how to

get ALL the variables displayed in a context and i did not expect (symbols) to work on context too ;-) nice nice...



Norman.
-- (define? (Cornflakes))