REBOL3 tracker
  0.9.12 beta
Ticket #0002060 User: anonymous

Project:



rss
TypeWish Statussubmitted Date18-Sep-2013 22:38
Versionr3 master CategoryNative Submitted byBrianH
PlatformAll Severityminor Prioritynormal

Summary REDUCE paren! evaluate and generate paren!
Description Have REDUCE of a paren! evaluate and generate a paren! of the results, the same way that REDUCE of a block! evaluates and generates a block!. All other datatypes should continue to pass through, as they do now - this includes path types, which don't have the right evaluation model for REDUCE to treat like a block.

No change to the argument evaluation style, so you'll have to use an expression that generates a paren as the argument rather than a literal paren.
Example code
; Current behavior
>> reduce quote (1 + 1)
== (1 + 1)
>> reduce (1 + 1)
== 2
>> head reduce/into quote (1 + 1) []
== (1 + 1)  ; Note that /into is ignored for non-block values (a different bug)

; Proposed behavior
>> reduce quote (1 + 1)
== (2)
>> reduce (1 + 1)
== 2
>> head reduce/into quote (1 + 1) []
== [1 + 1]  ; Results should be inserted inline, not as a nested value

Assigned ton/a Fixed in- Last Update18-Sep-2013 23:02


Comments

Date User Field Action Change
18-Sep-2013 23:02 BrianH Description Modified -
18-Sep-2013 22:44 BrianH Description Modified -
18-Sep-2013 22:44 BrianH Code Modified -
18-Sep-2013 22:38 BrianH Ticket Added -