Re: Name-space proposal
- Posted by Robert Craig <rds at Ra?idEuphori?.com> Aug 02, 2007
- 484 views
jacques deschĂȘnes wrote: > this is a reasonable proposal, I back it. What is in the main file of a > program > should have priority than what is in include in case of redefinition. That's how it *does* work. If a symbol is defined in the same file where the reference to it occurs, that symbol will be used, regardless of what is defined in other included files. It has been that way ever since 2.3 when the namespace feature was first introduced. Bernie muist be using version 2.2 or earlier, where namespaces didn't even exist. > Bernie Ryan wrote: > > > > Anybody: > > > > If name-space worked in this way it would solve a lot of problems. > > > > If a program contains a function foo()in the local main file and another > > > > file is included containing a foo() function. The interpeter would not > > > > stop but continue using the foo() function in the local main file. > > > > When the program ends; the program would issue a warning that there > > > > is a duplicate function foo() exists in include file xxx.e just > > > > as it lists unused constants etc. > > > > This would eliminate breaking code and allow debugging. > > > > There could also be a special flag Example: with_out_name_space > > > > to turn this on/off > > > > Bernie Regards, Rob Craig Rapid Deployment Software http://www.RapidEuphoria.com