[CLJ-1038] Docstring for deliver doesn't match behavior Created: 07/Aug/12 Updated: 01/Mar/13 Resolved: 24/Aug/12 |
|
| Status: | Closed |
| Project: | Clojure |
| Component/s: | None |
| Affects Version/s: | Release 1.3, Release 1.4 |
| Fix Version/s: | None |
| Type: | Defect | Priority: | Minor |
| Reporter: | Colin Jones | Assignee: | Colin Jones |
| Resolution: | Completed | Votes: | 0 |
| Labels: | documentation | ||
| Attachments: |
|
| Patch: | Code |
| Approval: | Ok |
| Description |
|
The docstring for deliver doesn't match the actual behavior. It says an exception gets thrown on multiple delivers, but that's no longer the case, as of 1.3 (hat tip to clgv on irc). user=> (doc deliver)
-------------------------
clojure.core/deliver
([promise val])
Alpha - subject to change.
Delivers the supplied value to the promise, releasing any pending
derefs. A subsequent call to deliver on a promise will throw an exception.
nil
(let [p (promise)] (deliver p "hi") (deliver p "bye") @p) ;=> "hi" This patch updates the docstring to reflect actual behavior: "will throw an exception." -> "will have no effect." |
| Comments |
| Comment by Stuart Halloway [ 10/Aug/12 1:48 PM ] |
|
Both patches are correct. Colin's patch documents the side effect, my variant also commits to the return values. Take your pick. |
| Comment by Rich Hickey [ 10/Aug/12 3:09 PM ] |
|
Don't doc return |
| Comment by Stuart Sierra [ 24/Aug/12 7:41 AM ] |
|
|
[CLJ-1027] Outdated documentation for gen-class's :exposes-methods option Created: 18/Jul/12 Updated: 18/Jul/12 |
|
| Status: | Open |
| Project: | Clojure |
| Component/s: | None |
| Affects Version/s: | Release 1.4 |
| Fix Version/s: | None |
| Type: | Defect | Priority: | Trivial |
| Reporter: | Dan Lidral-Porter | Assignee: | Unassigned |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | docs, documentation | ||
| Description |
|
The docstring for gen-class says the following regarding the :exposes-methods option: "It is sometimes necessary to call the superclass' implementation of an To me, this suggests that supplying something like `{foo fooSuper}` allows me to use the symbol `fooSuper` in my new method implementation. Doing this actually results in an error while compiling because `fooSuper` cannot be resolved. It seems that what actually happens is that a `fooSuper` instance method is defined, which calls the superclass's implementation. The docstring should be updated to reflect this. |
[CLJ-1019] ns-resolve doc has a typo Created: 30/Jun/12 Updated: 18/Aug/12 Resolved: 18/Aug/12 |
|
| Status: | Closed |
| Project: | Clojure |
| Component/s: | None |
| Affects Version/s: | Release 1.5 |
| Fix Version/s: | Release 1.5 |
| Type: | Defect | Priority: | Trivial |
| Reporter: | Gabriel Horner | Assignee: | Unassigned |
| Resolution: | Completed | Votes: | 0 |
| Labels: | documentation | ||
| Attachments: |
|
| Patch: | Code |
| Approval: | Ok |
| Description |
|
The doc string for ns-resolve has a typo: environement should be environment. |
| Comments |
| Comment by Andy Fingerhut [ 12/Jul/12 12:54 PM ] |
|
clj-1019-ns-resolve-doc-string-misspelling-patch1.txt dated July 12, 2012 is identical to fix_ns-resolve.patch of June 30, 2012, except it is in git format. It includes Gabriel's name and email address for proper attribution. |
| Comment by Aaron Bedra [ 14/Aug/12 8:07 PM ] |
|
Patch applies cleanly against 4004d267e124f12b65b0d7fb6522f32a75e3c4fb. Submitter is a confirmed CA signer. |
[CLJ-999] Wrong link in gh-pages index (api-index.html) Created: 18/May/12 Updated: 20/May/13 Resolved: 20/May/13 |
|
| Status: | Resolved |
| Project: | Clojure |
| Component/s: | None |
| Affects Version/s: | Release 1.3 |
| Fix Version/s: | None |
| Type: | Defect | Priority: | Trivial |
| Reporter: | Bogdan Popescu | Assignee: | Tom Faulhaber |
| Resolution: | Completed | Votes: | 0 |
| Labels: | docs, documentation | ||
| Patch: | None |
| Description |
|
The api-index.html includes wrong links for the following:
The links point to pages that do not exist. The problem is that the documentation for those entries is on a "parent" page, for example, the link clojure.core.protocols-api.html#clojure.core.protocols/internal-reduce should have been clojure.core-api.html#clojure.core.protocols/internal-reduce Not a huge bug for me, but you might want to get it fixed. And please give my huge thanks to whoever is in charge of the documentation, I'm the developer behind Dash, a Mac OS X documentation browser, and I was in the process of creating a documentation set for Clojure, and because you guys have an index, you made my work 1000 times easier. |
| Comments |
| Comment by Andy Fingerhut [ 11/Mar/13 3:01 PM ] |
|
Is this fixed now? Tom Faulhaber has regenerated the docs after the recent Clojure 1.5 release, and I think updated other things besides, so it might be. |
| Comment by Tom Faulhaber [ 11/Mar/13 4:43 PM ] |
|
Nope, not fixed. This one either slipped by me or came in right when I was changing jobs so didn't stick in my brain. I'll take a look now. Thanks for the report, Bogdan, and thanks for the bump, Andy to get it on my radar. |
| Comment by Gabriel Horner [ 10/May/13 4:00 PM ] |
|
Tom, I'm happy to help if you need it. Could you document on a wiki page how autodoc is run here? I couldn't find such a page. |
| Comment by Tom Faulhaber [ 20/May/13 4:18 PM ] |
|
This is fixed with gh-pages commit 919143e (autodoc doesn't follow the regular Clojure release path since it's a website built off the source checkins). |
| Comment by Tom Faulhaber [ 20/May/13 4:24 PM ] |
|
Gabriel, Thanks for the offer. I fixed this one, but may take you up on it if more come up. There is currently no wiki page about the autodoc process but it's an excellent suggestion. I'll put it on my list to write something up. In the meantime source on the autodoc program itself is at https://github.com/tomfaulhaber/autodoc and a description of how it works is at http://tomfaulhaber.github.io/autodoc. Two caveats: (1) autodoc is currently undergoing a bunch of work (thus this bug fix) in preparation for a new release and (2) the documentation doesn't talk much about how it's used for documenting Clojure itself. |
[CLJ-998] doc string for replace-first mentions non-existent replace-all Created: 18/May/12 Updated: 01/Mar/13 Resolved: 18/May/12 |
|
| Status: | Closed |
| Project: | Clojure |
| Component/s: | None |
| Affects Version/s: | Release 1.3 |
| Fix Version/s: | None |
| Type: | Defect | Priority: | Minor |
| Reporter: | Steve Miner | Assignee: | Unassigned |
| Resolution: | Duplicate | Votes: | 0 |
| Labels: | documentation | ||
| Attachments: |
|
| Patch: | Code |
| Description |
|
The doc string for clojure.string/replace-first says see also replace-all, which does not exist. The actual function is simply 'replace'. |
| Comments |
| Comment by Andy Fingerhut [ 18/May/12 11:42 AM ] |
|
|
[CLJ-980] Documentation for extend-type falsely implies that & is allowed in protocol fn signatures Created: 03/May/12 Updated: 19/Dec/12 |
|
| Status: | Open |
| Project: | Clojure |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Defect | Priority: | Trivial |
| Reporter: | Charles Duffy | Assignee: | Unassigned |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | documentation | ||
| Attachments: |
|
| Patch: | Code |
| Approval: | Incomplete |
| Description |
|
The documentation for extend-type contains the following example: (extend-type MyType
Countable
(cnt [c] ...)
Foo
(bar [x y] ...)
(baz ([x] ...) ([x y & zs] ...)))
However, [x y & zs] is not a valid parameter list for a protocol fn. The documentation should be appropriately amended. |
| Comments |
| Comment by John Szakmeister [ 25/May/12 4:00 AM ] |
|
v2 of the patch is simply converts the patch to git format. I made sure that Mr. Duffy got proper attribution. I also took a stab at a simple log message. Any problems with the latter are mine, and I'm happy to fix it up if necessary. |
| Comment by Aaron Bedra [ 15/Aug/12 10:08 PM ] |
|
This doesn't update the entire doc string. The expansion is updated, but the signature section isn't. Here's what shows up. user=> (doc extend-type)
-------------------------
clojure.core/extend-type
([t & specs])
Macro
A macro that expands into an extend call. Useful when you are
supplying the definitions explicitly inline, extend-type
automatically creates the maps required by extend. Propagates the
class as a type hint on the first argument of all fns.
(extend-type MyType
Countable
(cnt [c] ...)
Foo
(bar [x y] ...)
(baz ([x] ...) ([x y & zs] ...)))
expands into:
(extend MyType
Countable
{:cnt (fn [c] ...)}
Foo
{:baz (fn ([x] ...) ([x y ...] ...))
:bar (fn [x y] ...)})
|
| Comment by Tassilo Horn [ 25/Aug/12 6:44 AM ] |
|
This is very much related to http://dev.clojure.org/jira/browse/CLJ-1024. NOTE: While varargs are not supported in protocol declarations, dynamic extension of a protocol via extend (extend-type, extend-protocol) does allow for varargs and also destructuring, cause the method impls are actually normal clojure functions. So if a Foo protocol declares a (foo [this a b c]) method, you can extend/extend-type/extend-protocol it dynamically using (foo [this & more] (do-magick)) where `a b c` are conflated into the `more` parameter. However, that doesn't work for method implementations defined by deftype, defrecord, and reify. So with respect to the facts, the example in the docstring is actually correct, so I'm not sure if it should be changed. However, what's supported in which cases should be documented better as it is right now. |
[CLJ-973] doc for *data-readers* is wrong about the format for data_readers.clj Created: 14/Apr/12 Updated: 14/Apr/12 Resolved: 14/Apr/12 |
|
| Status: | Closed |
| Project: | Clojure |
| Component/s: | None |
| Affects Version/s: | Release 1.4 |
| Fix Version/s: | None |
| Type: | Defect | Priority: | Minor |
| Reporter: | Steve Miner | Assignee: | Stuart Halloway |
| Resolution: | Completed | Votes: | 0 |
| Labels: | documentation | ||
| Attachments: |
|
| Approval: | Ok |
| Description |
|
Sometime recently, the format for data_readers.clj changed to require a read-time literal map instead of pairs of symbols. The doc string for *data-readers* should be updated to reflect the change. |
| Comments |
| Comment by Steve Miner [ 14/Apr/12 9:59 AM ] |
|
Fixed doc string for *data-readers* |
[CLJ-965] clojure.org/patches should have link to JIRA workflow wiki page added, and most content removed Created: 04/Apr/12 Updated: 10/May/12 Resolved: 10/May/12 |
|
| Status: | Closed |
| Project: | Clojure |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Enhancement | Priority: | Minor |
| Reporter: | Andy Fingerhut | Assignee: | Unassigned |
| Resolution: | Completed | Votes: | 1 |
| Labels: | documentation | ||
| Patch: | Code |
| Description |
|
http://groups.google.com/group/clojure-dev/browse_frm/thread/12e90e460aec29cb Relevant text supporting this suggestion copied below: [1] http://dev.clojure.org/display/design/JIRA+workflow Only a few have permission to edit this page: [2] http://clojure.org/patches I have carefully reviewed the content of those two side by side, section by section, and it seems to me that they are either identical, or [1] is more up to date. I am not proposing getting rid of [2], but instead do this: Keep the first section headed "Submitting patches to Clojure and Clojure Contrib" exactly as it is now. Immediately under the heading "So You Have an Idea...", put a single link, perhaps with one sentence or phrase, that points at [1]. Delete all other text from there down on [2]. You will lose nothing worth saving, and you will save future confusion as what is now [2] gets more and more stale. |
| Comments |
| Comment by Andy Fingerhut [ 04/Apr/12 2:32 PM ] |
|
I am probably abusing the "Patch" attribute of this ticket. I've set it to Code to indicate that it is ready for screening/action, not that it actually has a patch. I suppose if you take a very broad view of patch, one that includes the English text describing the suggested web page changes to clojure.org/patches in the description, then it does have a patch. |
| Comment by Andy Fingerhut [ 24/Apr/12 4:09 PM ] |
|
Another link that would be nice to update: On http://clojure.org/contributing there is a link with text "preferred process for submitting" that links to http://clojure.org/patches. It should link to http://dev.clojure.org/display/design/JIRA+workflow instead. |
| Comment by Alex Miller [ 10/May/12 8:38 PM ] |
|
I have boldly made the suggested changes to the patches page as it seems imminently reasonable to avoid duplicating the more maintained version of the content. I added the sentence: "Great! For more info on the process of creating issues in JIRA, creating and filing patches, tracking, screening and vetting patches, please visit the JIRA workflow page on the dev wiki." with a big wide link target to the jira workflow page. If the powers that be deem my changes to be unsuitable, the powers that be can revert to the prior version here: |
| Comment by Alex Miller [ 10/May/12 8:40 PM ] |
|
I also changed the link on http://clojure.org/contributing per the other comment. |
| Comment by Andy Fingerhut [ 10/May/12 8:49 PM ] |
|
Between the two of us, Alex, we have just enough permissions to make the change to clojure.org and close the ticket |
[CLJ-953] drop-while doc string wrong, nil instead of logical false Created: 15/Mar/12 Updated: 30/Mar/12 Resolved: 30/Mar/12 |
|
| Status: | Closed |
| Project: | Clojure |
| Component/s: | None |
| Affects Version/s: | Release 1.3 |
| Fix Version/s: | Release 1.4 |
| Type: | Enhancement | Priority: | Trivial |
| Reporter: | Eric Schoonover | Assignee: | Alan Dipert |
| Resolution: | Completed | Votes: | 0 |
| Labels: | documentation, patch, | ||
| Attachments: |
|
| Patch: | Code |
| Approval: | Ok |
| Description |
"Returns a lazy sequence of the items in coll starting from the first - item for which (pred item) returns nil." + item for which (pred item) returns logical false." |
[CLJ-936] Improve docs about argument destructuring at clojure.org Created: 21/Feb/12 Updated: 01/Mar/13 Resolved: 27/Nov/12 |
|
| Status: | Closed |
| Project: | Clojure |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | Release 1.5 |
| Type: | Enhancement | Priority: | Minor |
| Reporter: | Jakub Holy | Assignee: | Unassigned |
| Resolution: | Completed | Votes: | 0 |
| Labels: | documentation, web | ||
| Approval: | Accepted |
| Description |
|
What:
Why: Thanks a lot! PS: I haven't found a better way to report this, such as a commenting capability on the page itself. |
| Comments |
| Comment by Andy Fingerhut [ 12/Mar/12 6:03 PM ] |
|
Jakub, I don't think I have authorization to edit those web pages in the way you suggest. I did want to comment that the most recent version of the Clojure cheatsheet at http://clojure.org/cheatsheet now has a link called "examples" in the "Special Forms" section that links to the 'let' section of the special forms documentation page. |
[CLJ-917] clojure.core/definterface is not included in the API docs Created: 23/Jan/12 Updated: 20/Oct/12 Resolved: 20/Oct/12 |
|
| Status: | Closed |
| Project: | Clojure |
| Component/s: | None |
| Affects Version/s: | Release 1.3 |
| Fix Version/s: | Release 1.5 |
| Type: | Defect | Priority: | Minor |
| Reporter: | Tassilo Horn | Assignee: | Unassigned |
| Resolution: | Completed | Votes: | 0 |
| Labels: | documentation | ||
| Attachments: |
|
| Patch: | Code |
| Approval: | Ok |
| Description |
|
Is definterface meant to be a public API? If yes, then it needs a docstring. |
| Comments |
| Comment by Tassilo Horn [ 25/Jan/12 2:28 PM ] |
|
This patch obsoletes the previous one. The only addition is the insertion of :added metadata which is needed to make the tests pass. |
| Comment by Tassilo Horn [ 08/Mar/12 3:53 AM ] |
|
Updated patch. |
| Comment by Stuart Sierra [ 23/Mar/12 9:04 AM ] |
|
Screened, pending question for Rich: "Is definterface meant to be a public API?" |
| Comment by Tassilo Horn [ 31/May/12 1:45 AM ] |
|
Rebased patch on current master. |
| Comment by Stuart Sierra [ 24/Aug/12 1:12 PM ] |
|
Screened again. Still applies as of commit 1c8eb16a14ce5daefef1df68d2f6b1f143003140 |
| Comment by Stuart Halloway [ 19/Oct/12 10:32 AM ] |
|
The CLJ-971 patch I just added is the same as the original with grammar corrections. |
| Comment by Tassilo Horn [ 20/Oct/12 5:48 AM ] |
|
Patch including Stu's grammar/typo fixes. Sorry, contributors like to show up in the commit history, so I couldn't resist stealing my patch back from you. |
[CLJ-900] Document defonce-like behavior of defmulti Created: 19/Dec/11 Updated: 19/Dec/11 |
|
| Status: | Open |
| Project: | Clojure |
| Component/s: | None |
| Affects Version/s: | Release 1.2, Release 1.3 |
| Fix Version/s: | None |
| Type: | Task | Priority: | Minor |
| Reporter: | Rasmus Svensson | Assignee: | Unassigned |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | documentation | ||
| Description |
|
Since Clojure 1.2 defmulti behaves similarly to defonce. This fact, and how one deals with it when doing interactive development, does not seem to be documented anywhere. This issue pops up fairly regularly in the #clojure channel. Commit that introduced the change: https://github.com/clojure/clojure/commit/1b8d5001ba094053b24c55829994785be422cfbf I can volunteer to update the docstrings and (if I get access to it) the clojure.org page. |