> Noha writes > Hi, > A few points:
> 1. I really, really think that it is a bad idea for the type of a > variable to change depending on how it is used (i.e. set! > vs. set~). That means that you should remove points 12 and 14, and > maybe some other points. I agree with you now, I was a bit too creative there :-) > 2. You shouldn't specify the semantics in terms of code, but by a > description. That means removing points 3, 4, 5, and 7 and replacing > them with text that says how the variables work. You can move the > same ideas down to the reference implementation, though - that is > good. I will in the end go there meanwhile I like to keep some code for clarity. > 3. I strongly suspect that you will find that MIT Scheme's fluid-let > has the semantics you want. If it doesn't, I would be interested to > see an example that shows the difference between that and the type > of variables that you want. I think that fluid parameters fluid-let are close in semantics. but I do not want the backtracking feature of fluid -let in some applications and it carries an overhead compared to just haveing variables and an init value. Note: I have been going back to guile-log to try to implement the ideas in actual code. I got it working and implemented in efficient C I hope. The code for e.g. any-interleave got 8x faster (Now About 10x slower then a simple all in stead of 80). My conclusion now is that to get an efficient implementation one needs to go back to dynamic-wind guards. And demand that redo-safeness imply that we assume that the code backtracks over the dynamic-wind at the state storage point. This is featurefull enough to satisfy most uses of redo/undo that I can think of. /Stefan