This site is a static rendering of the Trac instance that was used by R7RS-WG1 for its work on R7RS-small (PDF), which was ratified in 2013. For more information, see Home.

Source for ticket #398

cc


    

changetime

2012-08-27 07:16:26

component

WG1 - Core

description

R5RS says it's an error for a key to appear in more than one clause of `case` (or twice in the same clause, but that's trivial).  R6RS allows the same key to appear more than one clause, but insists on left-to-right testing throughout, like `cond`.  The R6RS editors thought this was better for machine-generated code, though worse for hand-written code.

I suggest a compromise: allow keys to appear in more than one clause, but behave as if the key appeared only in the first (leftmost) clause.  This allows hash-table or other non-left-to-right implementations.

id

398

keywords


    

milestone


    

owner

alexshinn

priority

major

reporter

cowan

resolution

wontfix

severity


    

status

closed

summary

Allow repeated keys in `case`

time

2012-06-10 08:49:29

type

defect

Changes

Change at time 2012-08-27 07:16:26

author

cowan

field

comment

newvalue


    

oldvalue

3

raw-time

1346026586407198

ticket

398

time

2012-08-27 07:16:26

Change at time 2012-08-27 07:16:26

author

cowan

field

resolution

newvalue

wontfix

oldvalue


    

raw-time

1346026586407198

ticket

398

time

2012-08-27 07:16:26

Change at time 2012-08-27 07:16:26

author

cowan

field

status

newvalue

closed

oldvalue

decided

raw-time

1346026586407198

ticket

398

time

2012-08-27 07:16:26

Change at time 2012-08-25 00:30:25

author

cowan

field

comment

newvalue

WG1 decided to keep the R5RS rules: no duplicate keys.

oldvalue

2

raw-time

1345829425224260

ticket

398

time

2012-08-25 00:30:25

Change at time 2012-08-25 00:30:25

author

cowan

field

status

newvalue

decided

oldvalue

new

raw-time

1345829425224260

ticket

398

time

2012-08-25 00:30:25

Change at time 2012-06-10 09:06:43

author

aag

field

comment

newvalue

If machine-generated code is the only justification for this change, then let's not make it.  It's so easy to eliminate repeated keys even in machine-generated code that there's no excuse for not doing so.

oldvalue

1

raw-time

1339294003024714

ticket

398

time

2012-06-10 09:06:43