docstring for CL:REPLACE - reference to target/source sequences not congruent with lambda list parameters
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
SBCL |
Fix Released
|
Low
|
Unassigned |
Bug Description
Verified current through commit 137b4d0 on Head
cl:replace has the following lambda-list:
(sequence1 sequence2 &rest args
&key (start1 0) (end1 nil) (start2 0) (end2 nil))
(documentation 'cl:replace 'function)
=> "The target sequence is destructively modified by copying successive
elements into it from the source sequence."
The docstring of cl:replace should reflect the function's parameters.
It is not clear what is being referenced by "target sequence" and
"source sequence". Something like the following would suffice to clarify:
"Destructively modify SEQUENCE-1 by copying successive elements
into it from SEQUENCE-2."
FTR following is from the "Description" from the spec for cl:replace:
"SEQUENCE-1 is destructively modified by copying successive elements
into it from SEQUENCE-2.
Destructively modifies SEQUENCE-1 by replacing the elements of
SUBSEQUENCE-1 bounded by START1 and END1 with the elements of
SUBSEQUENCE-2 bounded by START2 and END2.
..."
Including the second paragraph from above with the docstring of cl:replace might also be nice :)
(lisp-implement
=> "1.0.55.4-eee9d17"
Changed in sbcl: | |
status: | Fix Committed → Fix Released |
The above proposed modification to the docstring is wrong.
I'd assumed that the sequence parameter names were congruent with the spec and contained a #\- but they do not.
Following reflects SBCL's parameter names:
"Destructively modify SEQUENCE1 by copying successive elements into it from SEQUENCE2."