about summary refs log tree commit diff
path: root/src/test/rustdoc
AgeCommit message (Collapse)AuthorLines
2016-04-22show unstable status for deprecated itemsAndy Russell-0/+25
2016-04-22Only record the same impl oncemitaa-0/+43
Due to inlining it is possible to visit the same module multiple times during `<Cache as DocFolder>::fold_crate`, so we keep track of the modules we've already visited.
2016-04-22rustdoc: Cleanup ABI renderingOliver Middleton-5/+42
Use a common method for rendering `extern "<abi>"`. This now consistently shows `extern "C" fn` rather than just `extern fn`.
2016-04-21Auto merge of #33074 - mitaa:rdoc-irlst, r=alexcrichtonbors-0/+20
rustdoc: Fix the strip-hidden `ImplStripper` Instead of stripping impls which reference *stripped* items, we keep impls which reference *retained* items. We do this because when we strip an item we immediately return, and do not recurse into it - leaving the contained items non-stripped from the point of view of the `ImplStripper`. fixes #33069 r? @alexcrichton
2016-04-19Auto merge of #33002 - mitaa:rdoc-cross-impls, r=alexcrichtonbors-0/+130
rustdoc: refine cross-crate impl inlining This changes the current rule that impls within `doc(hidden)` modules aren't inlined, to only inlining impls where the implemented trait and type are reachable in documentation. fixes #14586 fixes #31948 .. and also applies the reachability checking to cross-crate links. fixes #28480 r? @alexcrichton
2016-04-19Auto merge of #32985 - caipre:rustdoc-disambiguate-impl-anchors, r=alexcrichtonbors-0/+27
rustdoc: Disambiguate anchors Closes https://github.com/rust-lang/rust/issues/32890
2016-04-18Rollup merge of #32558 - sanxiyn:rustdoc-self-link, r=steveklabnikSteve Klabnik-0/+16
Avoid linking to itself in implementors section of trait page Fix #32474.
2016-04-18Fix the strip-hidden `ImplStripper`mitaa-0/+20
Instead of stripping impls which reference *stripped* items, we keep impls which reference *retained* items. We do this because when we strip an item we immediately return, and do not recurse into it - leaving the contained items non-stripped from the point of view of the `ImplStripper`.
2016-04-17rustdoc: Disambiguate anchors for assoc item implsNick Platt-0/+27
2016-04-18Reachability check cross-crate linksmitaa-0/+23
2016-04-18Perform doc-reachability check for inlined implsmitaa-0/+107
This changes the current rule that impls within `doc(hidden)` modules aren't inlined, to only inlining impls where the implemented trait and type are reachable in documentation.
2016-04-15Add flag for whether an item is default or not.pierzchalski-0/+4
We don't want to render default item docs but previously `doctraititem` naively delegated to the trait definition in those cases. Updated tests to also check that this doesn't strip default item docs from the trait definition.
2016-04-15Add tests against weird provided/required method behaviourpierzchalski-7/+55
In `test/rustdoc/manual_impl.rs` there are now three structs: * S1 implements and documents required method `a_method`. * S2 implements and documents `a_method` as well as provided method `b_method`. * S3 implements `a_method` and `b_method`, but only documents `b_method`. For a struct, we want the rendered trait impls to include documentation if and only if it appears on the trait implementation itself (since users can just go to the trait definition for anything not covered in the impl docs). This means we expect: * S1, S2, and S3 to all include top-level trait impl docs. * S1, S2, and S3 to exclude all trait definition docs. * S1 to show impl docs for `a_method`. * S2 to show impl docs for `a_method` and `b_method`. * S3 to show impl docs for `b_method`. These tests cover those cases.
2016-04-14Delegate whether to print docblocks to 'document'pierzchalski-0/+26
Add test to check this resolves #24838 and #26871.
2016-04-11rustdoc: Fix testing no_run code blocksAlex Crichton-0/+19
This was a regression introduced by #31250 where the compiler deferred returning the results of compilation a little too late (after the `Stop` check was looked at). This commit alters the stop point to first try to return an erroneous `result` and only if it was successful return the sentinel `Err(0)`. Closes #31576
2016-04-06Add a testSeo Sanghyeon-0/+16
2016-04-02Refactor `HiddenStructField` into `StrippedItem`mitaa-0/+44
2016-04-02Make the rendering process less pass-awaremitaa-0/+48
Instead of hardcoding knowledge about the strip-private pass into the rendering process we represent (some) stripped items as `ItemEnum::StrippedItem`. Rustdoc will, for example, generate redirect pages for public items contained in private modules which have been re-exported to somewhere externally reachable - this will now not only work for the `strip-private` pass, but for other passes as well, such as the `strip-hidden` pass.
2016-03-27Load struct-variant data correctly from metadatamitaa-0/+2
2016-03-27Linkify associated types and constantsmitaa-1/+4
2016-03-27Correct anchor for links to associated trait itemsmitaa-0/+39
2016-03-23Rollup merge of #32434 - mitaa:rdoc-no-inline, r=alexcrichtonEduard-Mihai Burtescu-0/+33
rustdoc: Consider `doc(no_inline)` in crate-local inlining Imports with `doc(no_inline)` will not be inlined, even when `doc(inline)` is present. fixes #32343 r? @alexcrichton
2016-03-22Consider `doc(no_inline)` in crate-local inliningmitaa-0/+33
2016-03-22Omit `pub` for inlined variant-struct fieldsmitaa-0/+21
2016-03-12Auto merge of #32142 - mitaa:rdoc-maybe-inline-local, r=alexcrichtonbors-4/+56
rustdoc: improve crate-local inlining fixes #28537 r? @alexcrichton
2016-03-11Adjust rustdoc test for new restrictionAaron Turon-3/+3
2016-03-10Remove `feature(globs)` since they are stablemitaa-4/+0
2016-03-10Consider `doc(hidden)` for crate-local inliningmitaa-0/+27
2016-03-09Check for `doc(inline)` instead of `.*(inline)`mitaa-0/+29
2016-03-06Auto merge of #32055 - mitaa:rdoc-strip-priv-imports, r=alexcrichtonbors-1/+21
fixes #27104 r? @alexcrichton
2016-03-06Split out rustdoc pass to strip private importsmitaa-1/+21
2016-03-03Ignore a rustdoc test that does not work on betaBrian Anderson-0/+1
2016-02-27Clearly separate code blocks from other blocksmitaa-0/+70
For summary descriptions we need the first paragraph (adjacent lines until a blank line) - but the rendered markdown of a code block did not leave a blank line in the html and was thus included in the summary line.
2016-02-26Auto merge of #31903 - mitaa:rdoc-ghostly-impls, r=alexcrichtonbors-0/+18
fixes #29584 r? @alexcrichton
2016-02-26Don't inline impls from `doc(hidden)` modulesmitaa-0/+18
2016-02-26Auto merge of #31749 - nikomatsakis:compiletest-subdir, r=alexcrichtonbors-0/+0
You can now group tests into directories like `run-pass/borrowck` or `compile-fail/borrowck`. By default, all `.rs` files within any directory are considered tests: to ignore some directory, create a placeholder file called `compiletest-ignore-dir` (I had to do this for several existing directories). r? @alexcrichton cc @brson
2016-02-25Rollup merge of #31837 - mitaa:rdoc-inherent-assoc, r=alexcrichtonManish Goregaokar-0/+23
This effectively only records associated items from either inherent impls or trait definitions in the search-index. fixes #31808 r? @alexcrichton
2016-02-24Add compiletest-ignore-dir to existing subdirectories.Niko Matsakis-0/+0
2016-02-24Fix source-links for files with absolute-pathsmitaa-0/+17
`clean_srcpath` tries to make the source-path relative to `src_root`, but this didn't work since `src_root` itself wasn't absolute.
2016-02-23Don't show associated consts from trait implsmitaa-0/+23
2016-02-14Auto merge of #31614 - mitaa:rdoc_locitem_extmac, r=alexcrichtonbors-0/+21
fixes #26606 r? @alexcrichton
2016-02-13Auto merge of #31602 - mitaa:rdoc_doc_shorter, r=alexcrichtonbors-0/+16
fixes #25787 fixes #30366 r? @alexcrichton
2016-02-12Omit src-links for items from extern macrosmitaa-0/+21
If the span of a local item points into an external macro its source-file will be bogus.
2016-02-12Shorten docstrings after Markdown renderingmitaa-0/+16
2016-02-12Fix associated item identifiersmitaa-5/+5
Search results use the mapping found in `ItemType::to_static_str` for the identifier, which could not be found on the page in the case of associated items.
2016-01-28rustdoc: Add test for tuple renderingOliver Middleton-0/+18
2015-12-16Rollup merge of #30372 - sanxiyn:rustdoc-cfg, r=alexcrichtonManish Goregaokar-0/+16
Fix #30252.
2015-12-15Use --cfg when running doctestsSeo Sanghyeon-0/+16
Previously passed --cfg was used only when collecting doctests.
2015-12-12Support `#[deprecated]` in rustdocVadim Petrochenkov-0/+16
2015-12-08Auto merge of #30036 - mitaa:doc_id, r=alexcrichtonbors-0/+83
This expands the code which generates unique IDs for Markdown headers within a single block to each rendered page. fixes #25001 fixes #29449