File tree Expand file tree Collapse file tree 3 files changed +25
-4
lines changed Expand file tree Collapse file tree 3 files changed +25
-4
lines changed Original file line number Diff line number Diff line change 1
1
---
2
2
refs/heads/master: edeb4f1c86cbf6af8ef9874d4b3af50f721ea1b8
3
3
refs/heads/snap-stage3: 1af31d4974e33027a68126fa5a5a3c2c6491824f
4
- refs/heads/try: f6cfad68484f0ed591ce7be45aad612f7168de63
4
+ refs/heads/try: 5d955e17404778fb4db5fc33d732ac2738f76f34
5
5
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
6
6
refs/tags/release-0.2: c870d2dffb391e14efb05aa27898f1f6333a9596
7
7
refs/tags/release-0.3: b5f0d0f648d9a6153664837026ba1be43d3e2503
Original file line number Diff line number Diff line change @@ -496,9 +496,11 @@ strings are not terminated with `\0`. If you need a NUL-terminated string for
496
496
interoperability with C, you should use the ` CString ` type in the ` std::ffi `
497
497
module.
498
498
499
- The standard library includes type aliases and function definitions for the C
500
- standard library in the ` libc ` module, and Rust links against ` libc ` and ` libm `
501
- by default.
499
+ The [ ` libc ` crate on crates.io] [ libc ] includes type aliases and function
500
+ definitions for the C standard library in the ` libc ` module, and Rust links
501
+ against ` libc ` and ` libm ` by default.
502
+
503
+ [ libc ] : https://crates.io/crates/libc
502
504
503
505
# The "nullable pointer optimization"
504
506
Original file line number Diff line number Diff line change
1
+ // Copyright 2015 The Rust Project Developers. See the COPYRIGHT
2
+ // file at the top-level directory of this distribution and at
3
+ // http://rust-lang.org/COPYRIGHT.
4
+ //
5
+ // Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
6
+ // http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
7
+ // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
8
+ // option. This file may not be copied, modified, or distributed
9
+ // except according to those terms.
10
+
11
+ use std:: ops:: Add ;
12
+
13
+ fn foo < T > ( x : T ) -> <i32 as Add < T > >:: Output where i32 : Add < T > {
14
+ 42i32 + x
15
+ }
16
+
17
+ fn main ( ) {
18
+ println ! ( "{}" , foo( 0i32 ) ) ;
19
+ }
You can’t perform that action at this time.
0 commit comments