Sysop: | Amessyroom |
---|---|
Location: | Fayetteville, NC |
Users: | 28 |
Nodes: | 6 (1 / 5) |
Uptime: | 45:17:55 |
Calls: | 422 |
Calls today: | 1 |
Files: | 1,024 |
Messages: | 90,304 |
If both X and Y contain foo, then saying just "foo" is ambiguous and the >compiler flags it as an error. You are required to say X.foo or Y.foo
to indicate which one you want.
Is there a simple way to do something like that in Forth, to get an
error or at least a warning, if the same symbol occurs in multiple
wordlists in the search order?
Of course that only produces a warning if you actually access FOO
(unlike what you specified), but I think it's the same for Haskell.
In Haskell, if you import packages X and Y, and X contains a symbol
"foo", you can refer to it as just "foo" or explicitly as X.foo.
If both X and Y contain foo, then saying just "foo" is ambiguous and the >compiler flags it as an error. You are required to say X.foo or Y.foo
to indicate which one you want.
Is there a simple way to do something like that in Forth, to get an
error or at least a warning, if the same symbol occurs in multiple
wordlists in the search order?
Thanks.