Type | Bug | Status | dismissed | Date | 22-Jan-2014 02:27 |
---|---|---|---|---|---|
Version | r3 master | Category | Datatype | Submitted by | fork |
Platform | All | Severity | major | Priority | normal |
Summary | Variables containing LIT-WORD! decay to WORD! in evaluator, shouldn't (?) |
---|---|
Description |
I realize that when the evaluator hits a LIT-WORD! literal, then by default it needs to become a WORD!. That makes obvious sense. >> type? 'x == word! If you *really* wanted a lit-word, you need to quote it: >> type? quote 'x == lit-word! But I find this puzzling: >> foo: quote 'x == 'x >> type? foo == word! The variable holds a lit-word!, so what is the purpose of forcing this to have to be a get-word! case? >> type? :foo == lit-word! It makes meta-programming difficult when your lit-word! tinkertoys are acting like this. I understand that functions must default to invocation for the language to work, but this doesn't seem to have value. What is the motivation? Note that PARSE does not decay them: >> parse [x x x] [3 foo] == true |
Example code |
Current behavior: >> foo: quote 'x == 'x >> type? foo == word! Desired behavior: >> foo: quote 'x == 'x >> type? foo == lit-word! |
Assigned to | n/a | Fixed in | - | Last Update | 20-Sep-2015 07:12 |
---|
Comments | |
---|---|
(0004218)
abolka 22-Jan-2014 02:45 |
Possibly a duplicate of #1434 (esp. see Ladislav's comment 0003180 / 5-May-2011 12:39, which also suggests the same desired behaviour). |
(0004252)
BrianH 20-Feb-2014 21:04 |
Ladislav's solution implemented in https://github.com/rebol/rebol/pull/184 |
Date | User | Field | Action | Change |
---|---|---|---|---|
20-Sep-2015 07:12 | abolka | Status | Modified | pending => dismissed |
26-Feb-2014 16:17 | Ladislav | Severity | Modified | minor => major |
20-Feb-2014 21:04 | BrianH | Comment : 0004252 | Added | - |
20-Feb-2014 21:04 | BrianH | Category | Modified | Unspecified => Datatype |
20-Feb-2014 21:04 | BrianH | Status | Modified | submitted => pending |
20-Feb-2014 21:04 | BrianH | Type | Modified | Issue => Bug |
22-Jan-2014 02:45 | abolka | Comment : 0004218 | Added | - |
22-Jan-2014 02:28 | fork | Description | Modified | - |
22-Jan-2014 02:28 | fork | Code | Modified | - |
22-Jan-2014 02:27 | fork | Ticket | Added | - |