Skip to content

Commit 03bacd3

Browse files
committed
---
yaml --- r: 148822 b: refs/heads/try2 c: 003ce50 h: refs/heads/master v: v3
1 parent 7c2a0b5 commit 03bacd3

File tree

18 files changed

+130
-201
lines changed

18 files changed

+130
-201
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ refs/heads/snap-stage3: 78a7676898d9f80ab540c6df5d4c9ce35bb50463
55
refs/heads/try: 519addf6277dbafccbb4159db4b710c37eaa2ec5
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b
8-
refs/heads/try2: 16f1a72f0ab6ebf9e3279e3dd4873b6dc13220ec
8+
refs/heads/try2: 003ce502350ed1e374b740ee2d719e500c165615
99
refs/heads/dist-snap: ba4081a5a8573875fed17545846f6f6902c8ba8d
1010
refs/tags/release-0.2: c870d2dffb391e14efb05aa27898f1f6333a9596
1111
refs/tags/release-0.3: b5f0d0f648d9a6153664837026ba1be43d3e2503

branches/try2/src/etc/zsh/_rust

Lines changed: 40 additions & 70 deletions
Original file line numberDiff line numberDiff line change
@@ -5,110 +5,80 @@ local -a _rustc_opts_switches _rustc_opts_lint _rustc_opts_debug
55
typeset -A opt_args
66

77
_rustc_opts_switches=(
8-
--android-cross-path'[The path to the Android NDK]'
9-
--ar'[Program to use for managing archives instead of the default.]'
108
--bin'[Compile an executable crate (default)]'
119
-c'[Compile and assemble, but do not link]'
1210
--cfg'[Configure the compilation environment]'
13-
--crate-id'[Output the crate id and exit]'
14-
--crate-file-name'[Output the file(s) that would be written if compilation continued and exit]'
15-
--crate-name'[Output the crate name and exit]'
16-
--dep-info'[Output dependency info to <filename> after compiling]'
17-
--dylib'[Compile a dynamic library crate]'
1811
--emit-llvm'[Produce an LLVM bitcode file]'
1912
{-h,--help}'[Display this message]'
2013
-L'[Add a directory to the library search path]'
2114
--lib'[Compile a library crate]'
2215
--linker'[Program to use for linking instead of the default.]'
2316
--link-args'[FLAGS is a space-separated list of flags passed to the linker]'
24-
--llvm-args'[A list of arguments to pass to llvm, comma separated]'
2517
--ls'[List the symbols defined by a library crate]'
26-
--no-analysis'[Parse and expand the output, but run no analysis or produce output]'
27-
--no-rpath'[Disables setting the rpath in libs/exes]'
2818
--no-trans'[Run all passes except translation; no output]'
2919
-O'[Equivalent to --opt-level=2]'
3020
-o'[Write output to <filename>]'
3121
--opt-level'[Optimize with possible levels 0-3]'
3222
--out-dir'[Write output to compiler-chosen filename in <dir>]'
3323
--parse-only'[Parse only; do not compile, assemble, or link]'
34-
--passes'[Comma or space separated list of pass names to use]'
3524
--pretty'[Pretty-print the input instead of compiling]'
36-
--rlib'[Compile a rust library crate as an rlib file]'
3725
-S'[Compile only; do not assemble or link]'
3826
--save-temps'[Write intermediate files (.bc, .opt.bc, .o) in addition to normal output]'
39-
--staticlib'[Compile a static library crate]'
4027
--sysroot'[Override the system root]'
4128
--test'[Build a test harness]'
4229
--target'[Target triple cpu-manufacturer-kernel\[-os\] to compile]'
4330
--target-cpu'[Select target processor (llc -mcpu=help for details)]'
4431
--target-feature'[Target specific attributes (llc -mattr=help for details)]'
32+
--android-cross-path'[The path to the Android NDK]'
4533
{-v,--version}'[Print version info and exit]'
4634
)
4735
_rustc_opts_lint=(
48-
'attribute-usage[detects bad use of attributes]'
36+
'path-statement[path statements with no effect]'
37+
'missing-trait-doc[detects missing documentation for traits]'
38+
'missing-struct-doc[detects missing documentation for structs]'
4939
'ctypes[proper use of std::libc types in foreign modules]'
50-
'dead-assignment[detect assignments that will never be read]'
51-
'dead-code[detect piece of code that will never be used]'
52-
'default-type-param-usage[prevents explicitly setting a type parameter with a default]'
53-
'deprecated[detects use of #\[deprecated\] items]'
54-
'experimental[detects use of #\[experimental\] items]'
40+
"unused-mut[detect mut variables which don't need to be mutable]"
41+
'unused-imports[imports that are never used]'
5542
'heap-memory[use of any (~ type or @ type) heap memory]'
56-
'managed-heap-memory[use of managed (@ type) heap memory]'
57-
'missing-doc[detects missing documentation for public members]'
58-
'non-camel-case-types[types, variants and traits should have camel case names]'
59-
'non-uppercase-pattern-statics[static constants in match patterns should be all caps]'
60-
'non-uppercase-statics[static constants should have uppercase identifiers]'
61-
'owned-heap-memory[use of owned (~ type) heap memory]'
62-
'path-statement[path statements with no effect]'
63-
'type-limits[comparisons made useless by limits of the types involved]'
64-
'type-overflow[literal out of range for its type]'
65-
'unknown-crate-type[unknown crate type found in #\[crate_type\] directive]'
66-
'unknown-features[unknown features found in crate-level #\[feature\] directives]'
67-
'unnecessary-allocation[detects unnecessary allocations that can be eliminated]'
68-
'unnecessary-parens[`if`, `match`, `while` and `return` do not need parentheses]'
69-
'unnecessary-qualification[detects unnecessarily qualified names]'
70-
'unnecessary-typecast[detects unnecessary type casts, that can be removed]'
71-
'unreachable-code[detects unreachable code]'
43+
'default-methods[allow default methods]'
44+
'unused-variable[detect variables which are not used in any way]'
45+
'dead-assignment[detect assignments that will never be read]'
7246
'unrecognized-lint[unrecognized lint attribute]'
73-
'unsafe-block[usage of an `unsafe` block]'
74-
'unstable[detects use of #\[unstable\] items (incl. items with no stability attribute)]'
75-
'unused-imports[imports that are never used]'
76-
'unused-must-use[unused result of an type flagged as #\[must_use\]]'
77-
"unused-mut[detect mut variables which don't need to be mutable]"
78-
'unused-result[unused result of an expression in a statement]'
47+
'type-limits[comparisons made useless by limits of the types involved]'
7948
'unused-unsafe[unnecessary use of an `unsafe` block]'
80-
'unused-variable[detect variables which are not used in any way]'
81-
'warnings[mass-change the level for lints which produce warnings]'
82-
'while-true[suggest using `loop { }` instead of `while true { }`]'
49+
'while-true[suggest using loop { } instead of while(true) { }]'
50+
'non-camel-case-types[types, variants and traits should have camel case names]'
51+
'managed-heap-memory[use of managed (@ type) heap memory]'
52+
'unnecessary-allocation[detects unnecessary allocations that can be eliminated]'
53+
'owned-heap-memory[use of owned (~ type) heap memory]'
8354
)
8455

8556
_rustc_opts_debug=(
86-
'asm-comments[generate comments into the assembly (may change behavior)]'
87-
'borrowck-stats[gather borrowck statistics]'
88-
'count-llvm-insns[count where LLVM instrs originate]'
89-
'count-type-sizes[count the sizes of aggregate types]'
90-
'debug-info[Produce debug info (experimental)]'
91-
'debug-llvm[enable debug output from LLVM]'
92-
'extra-debug-info[Extra debugging info (experimental)]'
93-
'gc[Garbage collect shared data (experimental)]'
94-
'gen-crate-map[Force generation of a toplevel crate map]'
95-
'lto[Perform LLVM link-time optimizations]'
96-
'meta-stats[gather metadata statistics]'
97-
"no-integrated-as[Use external assembler rather than LLVM's integrated one]"
98-
'no-landing-pads[omit landing pads for unwinding]'
99-
'no-opt[do not optimize, even if -O is passed]'
100-
"no-prepopulate-passes[Don't pre-populate the pass managers with a list of passes, only use the passes from --passes]"
101-
"no-vectorize-loops[Don't run the loop vectorization optimization passes]"
102-
"no-vectorize-slp[Don't run LLVM's SLP vectorization passes]"
103-
'no-verify[skip LLVM verification]'
104-
'prefer-dynamic[Prefer dynamic linking to static linking]'
105-
'print-link-args[Print the arguments passed to the linker]'
106-
'print-llvm-passes[Prints the llvm optimization passes being run]'
107-
'soft-float[Generate software floating point library calls]'
108-
'time-llvm-passes[measure time of each LLVM pass]'
109-
'time-passes[measure time of each rustc pass]'
110-
'trans-stats[gather trans statistics]'
111-
'verbose[in general, enable more debug printouts]'
57+
'verbose:in general, enable more debug printouts'
58+
'time-passes:measure time of each rustc pass'
59+
'count-llvm-insns:count where LLVM instrs originate'
60+
'time-llvm-passes:measure time of each LLVM pass'
61+
'trans-stats:gather trans statistics'
62+
'asm-comments:generate comments into the assembly (may change behavior)'
63+
'no-verify:skip LLVM verification'
64+
'trace:emit trace logs'
65+
'coherence:perform coherence checking'
66+
'borrowck-stats:gather borrowck statistics'
67+
"borrowck-note-pure:note where purity is req'd"
68+
"borrowck-note-loan:note where loans are req'd"
69+
'no-landing-pads:omit landing pads for unwinding'
70+
'debug-llvm:enable debug output from LLVM'
71+
'count-type-sizes:count the sizes of aggregate types'
72+
'meta-stats:gather metadata statistics'
73+
'no-opt:do not optimize, even if -O is passed'
74+
'print-link-args:Print the arguments passed to the linker'
75+
'gc:Garbage collect shared data (experimental)'
76+
'jit:Execute using JIT (experimental)'
77+
'extra-debug-info:Extra debugging info (experimental)'
78+
'debug-info:Produce debug info (experimental)'
79+
'static:Use or produce static libraries or binaries (experimental)'
80+
'no-debug-borrows:do not show where borrow checks fail'
81+
'lint-llvm:Run the LLVM lint pass on the pre-optimization IR'
11282
)
11383

11484
_rustc_opts_fun_lint(){

branches/try2/src/librustdoc/html/escape.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ use std::fmt;
1919
/// string when passed to a format string.
2020
pub struct Escape<'a>(&'a str);
2121

22-
impl<'a> fmt::Default for Escape<'a> {
22+
impl<'a> fmt::Show for Escape<'a> {
2323
fn fmt(s: &Escape<'a>, fmt: &mut fmt::Formatter) {
2424
// Because the internet is always right, turns out there's not that many
2525
// characters to escape: http://stackoverflow.com/questions/7381974

branches/try2/src/librustdoc/html/format.rs

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
//! HTML formatting module
1212
//!
13-
//! This module contains a large number of `fmt::Default` implementations for
13+
//! This module contains a large number of `fmt::Show` implementations for
1414
//! various types in `rustdoc::clean`. These implementations all currently
1515
//! assume that HTML output is desired, although it may be possible to redesign
1616
//! them in the future to instead emit any format desired.
@@ -47,7 +47,7 @@ impl PuritySpace {
4747
}
4848
}
4949

50-
impl fmt::Default for clean::Generics {
50+
impl fmt::Show for clean::Generics {
5151
fn fmt(g: &clean::Generics, f: &mut fmt::Formatter) {
5252
if g.lifetimes.len() == 0 && g.type_params.len() == 0 { return }
5353
f.buf.write("&lt;".as_bytes());
@@ -77,14 +77,14 @@ impl fmt::Default for clean::Generics {
7777
}
7878
}
7979

80-
impl fmt::Default for clean::Lifetime {
80+
impl fmt::Show for clean::Lifetime {
8181
fn fmt(l: &clean::Lifetime, f: &mut fmt::Formatter) {
8282
f.buf.write("'".as_bytes());
8383
f.buf.write(l.get_ref().as_bytes());
8484
}
8585
}
8686

87-
impl fmt::Default for clean::TyParamBound {
87+
impl fmt::Show for clean::TyParamBound {
8888
fn fmt(bound: &clean::TyParamBound, f: &mut fmt::Formatter) {
8989
match *bound {
9090
clean::RegionBound => {
@@ -97,7 +97,7 @@ impl fmt::Default for clean::TyParamBound {
9797
}
9898
}
9999

100-
impl fmt::Default for clean::Path {
100+
impl fmt::Show for clean::Path {
101101
fn fmt(path: &clean::Path, f: &mut fmt::Formatter) {
102102
if path.global { f.buf.write("::".as_bytes()) }
103103
for (i, seg) in path.segments.iter().enumerate() {
@@ -269,7 +269,7 @@ fn typarams(w: &mut io::Writer, typarams: &Option<~[clean::TyParamBound]>) {
269269
}
270270
}
271271

272-
impl fmt::Default for clean::Type {
272+
impl fmt::Show for clean::Type {
273273
fn fmt(g: &clean::Type, f: &mut fmt::Formatter) {
274274
match *g {
275275
clean::TyParamBinder(id) | clean::Generic(id) => {
@@ -374,7 +374,7 @@ impl fmt::Default for clean::Type {
374374
}
375375
}
376376

377-
impl fmt::Default for clean::FnDecl {
377+
impl fmt::Show for clean::FnDecl {
378378
fn fmt(d: &clean::FnDecl, f: &mut fmt::Formatter) {
379379
write!(f.buf, "({args}){arrow, select, yes{ -&gt; {ret}} other{}}",
380380
args = d.inputs,
@@ -383,7 +383,7 @@ impl fmt::Default for clean::FnDecl {
383383
}
384384
}
385385

386-
impl fmt::Default for ~[clean::Argument] {
386+
impl fmt::Show for ~[clean::Argument] {
387387
fn fmt(inputs: &~[clean::Argument], f: &mut fmt::Formatter) {
388388
let mut args = ~"";
389389
for (i, input) in inputs.iter().enumerate() {
@@ -397,7 +397,7 @@ impl fmt::Default for ~[clean::Argument] {
397397
}
398398
}
399399

400-
impl<'a> fmt::Default for Method<'a> {
400+
impl<'a> fmt::Show for Method<'a> {
401401
fn fmt(m: &Method<'a>, f: &mut fmt::Formatter) {
402402
let Method(selfty, d) = *m;
403403
let mut args = ~"";
@@ -433,7 +433,7 @@ impl<'a> fmt::Default for Method<'a> {
433433
}
434434
}
435435

436-
impl fmt::Default for VisSpace {
436+
impl fmt::Show for VisSpace {
437437
fn fmt(v: &VisSpace, f: &mut fmt::Formatter) {
438438
match v.get() {
439439
Some(ast::Public) => { write!(f.buf, "pub "); }
@@ -443,7 +443,7 @@ impl fmt::Default for VisSpace {
443443
}
444444
}
445445

446-
impl fmt::Default for PuritySpace {
446+
impl fmt::Show for PuritySpace {
447447
fn fmt(p: &PuritySpace, f: &mut fmt::Formatter) {
448448
match p.get() {
449449
ast::UnsafeFn => write!(f.buf, "unsafe "),
@@ -453,7 +453,7 @@ impl fmt::Default for PuritySpace {
453453
}
454454
}
455455

456-
impl fmt::Default for clean::ViewPath {
456+
impl fmt::Show for clean::ViewPath {
457457
fn fmt(v: &clean::ViewPath, f: &mut fmt::Formatter) {
458458
match *v {
459459
clean::SimpleImport(ref name, ref src) => {
@@ -478,7 +478,7 @@ impl fmt::Default for clean::ViewPath {
478478
}
479479
}
480480

481-
impl fmt::Default for clean::ImportSource {
481+
impl fmt::Show for clean::ImportSource {
482482
fn fmt(v: &clean::ImportSource, f: &mut fmt::Formatter) {
483483
match v.did {
484484
// FIXME: shouldn't be restricted to just local imports
@@ -495,7 +495,7 @@ impl fmt::Default for clean::ImportSource {
495495
}
496496
}
497497

498-
impl fmt::Default for clean::ViewListIdent {
498+
impl fmt::Show for clean::ViewListIdent {
499499
fn fmt(v: &clean::ViewListIdent, f: &mut fmt::Formatter) {
500500
match v.source {
501501
// FIXME: shouldn't be limited to just local imports

branches/try2/src/librustdoc/html/layout.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ pub struct Page<'a> {
2424
root_path: &'a str,
2525
}
2626

27-
pub fn render<T: fmt::Default, S: fmt::Default>(
27+
pub fn render<T: fmt::Show, S: fmt::Show>(
2828
dst: &mut io::Writer, layout: &Layout, page: &Page, sidebar: &S, t: &T)
2929
{
3030
write!(dst,

branches/try2/src/librustdoc/html/markdown.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
//! (bundled into the rust runtime). This module self-contains the C bindings
1515
//! and necessary legwork to render markdown, and exposes all of the
1616
//! functionality through a unit-struct, `Markdown`, which has an implementation
17-
//! of `fmt::Default`. Example usage:
17+
//! of `fmt::Show`. Example usage:
1818
//!
1919
//! ```rust,ignore
2020
//! use rustdoc::html::markdown::Markdown;
@@ -32,7 +32,7 @@ use std::str;
3232
use std::unstable::intrinsics;
3333
use std::vec;
3434

35-
/// A unit struct which has the `fmt::Default` trait implemented. When
35+
/// A unit struct which has the `fmt::Show` trait implemented. When
3636
/// formatted, this struct will emit the HTML corresponding to the rendered
3737
/// version of the contained markdown string.
3838
pub struct Markdown<'a>(&'a str);
@@ -209,7 +209,7 @@ pub fn find_testable_code(doc: &str, tests: &mut ::test::Collector) {
209209
}
210210
}
211211

212-
impl<'a> fmt::Default for Markdown<'a> {
212+
impl<'a> fmt::Show for Markdown<'a> {
213213
fn fmt(md: &Markdown<'a>, fmt: &mut fmt::Formatter) {
214214
let Markdown(md) = *md;
215215
// This is actually common enough to special-case

branches/try2/src/librustdoc/html/render.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -801,7 +801,7 @@ impl<'a> Item<'a> {
801801
}
802802
}
803803

804-
impl<'a> fmt::Default for Item<'a> {
804+
impl<'a> fmt::Show for Item<'a> {
805805
fn fmt(it: &Item<'a>, fmt: &mut fmt::Formatter) {
806806
match attr::find_stability(it.item.attrs.iter()) {
807807
Some(ref stability) => {
@@ -990,7 +990,7 @@ fn item_module(w: &mut Writer, cx: &Context,
990990
match myitem.inner {
991991
clean::StaticItem(ref s) | clean::ForeignStaticItem(ref s) => {
992992
struct Initializer<'a>(&'a str);
993-
impl<'a> fmt::Default for Initializer<'a> {
993+
impl<'a> fmt::Show for Initializer<'a> {
994994
fn fmt(s: &Initializer<'a>, f: &mut fmt::Formatter) {
995995
let Initializer(s) = *s;
996996
if s.len() == 0 { return; }
@@ -1491,7 +1491,7 @@ fn item_typedef(w: &mut Writer, it: &clean::Item, t: &clean::Typedef) {
14911491
document(w, it);
14921492
}
14931493

1494-
impl<'a> fmt::Default for Sidebar<'a> {
1494+
impl<'a> fmt::Show for Sidebar<'a> {
14951495
fn fmt(s: &Sidebar<'a>, fmt: &mut fmt::Formatter) {
14961496
let cx = s.cx;
14971497
let it = s.item;
@@ -1556,7 +1556,7 @@ fn build_sidebar(m: &clean::Module) -> HashMap<~str, ~[~str]> {
15561556
return map;
15571557
}
15581558

1559-
impl<'a> fmt::Default for Source<'a> {
1559+
impl<'a> fmt::Show for Source<'a> {
15601560
fn fmt(s: &Source<'a>, fmt: &mut fmt::Formatter) {
15611561
let Source(s) = *s;
15621562
let lines = s.lines().len();

0 commit comments

Comments
 (0)