[Factor-talk] menu reloading

2007-01-11 Thread Eduardo Cavazos
Chris, Just to clarify, if you make a simple .xsession which just launches an xterm and then do: ./f -shell=tty USE: factory f start-factory then you can edit the menus in factory-rc, do a \ apps-menu reload in that terminal and it should work. If you start factory like this: ./f -shell=tty

Re: [Factor-talk] menu reloading

2007-01-11 Thread Eduardo Cavazos
Chris, Here's a common sense solution: add a reload menus item to the root-menu. :-) Of course, this works because the reload itself is kicked off from within the thread that is in the same namespace as the original menus. I think this is the right thing. { { xterm [ xterm system

Re: [Factor-talk] reload

2007-01-11 Thread Slava Pestov
On 11-Jan-07, at 3:51 PM, Eduardo Cavazos wrote: Slava, It would be nice if \ word reload actually only loaded the specified word. Too difficult and not worth the hassle. If running the file has side effects then reload can cause problems. This is the actual problem. Remember our

[Factor-talk] Compiler error in libs/vars

2007-01-11 Thread Eduardo Cavazos
Slava, I get a compiler error when loading libs/vars. It complains about unbalanced branches in (repeat) and the call chain goes up to let. But let never calls that word directly. It get's there from each. Do you know what's going on? Paste this into the listener: : let ( vars body -- result

Re: [Factor-talk] The use and abuse of variables

2007-01-11 Thread Daniel Ehrenberg
The problem with your (( )) macro is that it isn't automatically scoped, and could lead to errors or confusion. Also, it encourages abuse of variables, and is just unnecessary. On 1/11/07, Eduardo Cavazos [EMAIL PROTECTED] wrote: Hello, I'm working on a new vars vocabulary. This one works like

Re: [Factor-talk] The use and abuse of variables

2007-01-11 Thread Chris Double
In the system I changed it so foo is used as the variable. Isn't using a symbol the right thing though? Using a string means you can get clashes with any other file that uses the same string name as a variable. Chris. -- http://www.bluishcoder.co.nz

Re: [Factor-talk] The use and abuse of variables

2007-01-11 Thread Slava Pestov
On 11-Jan-07, at 6:45 PM, Eduardo Cavazos wrote: : #foo ( -- ... ) ! Call the value of foo. E.g. foo get call I don't like this. In the old vars system, VAR: foo in addition to making getter and setter words, also setup up foo to be a symbol. In the system I changed it

Re: [Factor-talk] The use and abuse of variables

2007-01-11 Thread Eduardo Cavazos
On Thursday 11 January 2007 21:52, Chris Double wrote: In the system I changed it so foo is used as the variable. Isn't using a symbol the right thing though? Using a string means you can get clashes with any other file that uses the same string name as a variable. Chris, Wow, you have a

Re: [Factor-talk] The use and abuse of variables

2007-01-11 Thread Slava Pestov
On 12-Jan-07, at 2:43 AM, Eduardo Cavazos wrote: On Friday 12 January 2007 01:03, Slava Pestov wrote: If you want something closer to Scheme, you might want to investigate implementing lexically scoped variables, instead of extending the dynamically scoped namespace system from the core.