Digest #106 2020-07-28

Contributions

[143] 2020-07-26 11:22:42 JamesNorris wrote:

requestClarification - Does the wording of the rules imply that if you SYNONYM a word with the same name in the same wordlist and then 'look it up', you will get the old word?

At first glance when I read the sentence, the way it was worded it seemed that you would always find the old word. The sentence is this: 'Newname may be the same as oldname; when looking up oldname, newname shall not be found.' When I first read it, because of the semi colon, I was under the impression that the part of the sentence after the semicolon had something to do with what was said before the semi colon. After thinking about it, I realized that this was probably not your intent. If you changed the order and used a period, it might be a lot clearer. Also, other parts of the standard refer to 'looking up' as 'finding'. Might want to be consistent with terms. So, something like this: 'When finding oldname, newname shall not be found. Newname may be the same as oldname.'

Replies

[r386] 2020-07-27 09:29:43 AntonErtl replies:

requestClarification - Does the wording of the rules imply that if you SYNONYM a word with the same name in the same wordlist and then 'look it up', you will get the old word?

The part "when looking up oldname, newname shall not be found" is intended to specify what happens during the execution of SYNONYM, not later. I.e., when you define

SYNONYM + +

newname '+' is not visible while finding oldname '+' to determine what newname is a synonym of. I agree that "find" is better than "look up" here (e.g., compare with ":", which makes the defined word not "findable").

In the process of tightening SYNONYM we might also fix this. E.g., one might write:

For both strings skip leading space delimiters. Parse newname and oldname delimited by a space. Find oldname, and use the result in the semantics below. Define newname, with the semantics defined below. Note that newname may be the same as oldname.

This resolves the issue by specifying that oldname is found before newname is defined.


[r387] 2020-07-27 14:00:18 JamesNorris replies:

requestClarification - Does the wording of the rules imply that if you SYNONYM a word with the same name in the same wordlist and then 'look it up', you will get the old word?

The new way you worded it is a lot clearer to me. thumbs up