about summary refs log tree commit diff
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2015-07-11 07:40:27 +0000
committerbors <bors@rust-lang.org>2015-07-11 07:40:27 +0000
commit1b28ffa5216c845d1cef6b0cb3e5ac7db12025d0 (patch)
tree9c77611c90018f5b88bb00e3e06d23dbd60a4413
parentf7f28c8b26af35fb495f60b43d0c6361c587045f (diff)
parent25b14375b752ea88f91af37ec2b5c042cd10927b (diff)
downloadrust-1b28ffa5216c845d1cef6b0cb3e5ac7db12025d0.tar.gz
rust-1b28ffa5216c845d1cef6b0cb3e5ac7db12025d0.zip
Auto merge of #26961 - Manishearth:rollup, r=Manishearth
- Successful merges: #26932, #26936, #26943, #26944
- Failed merges: 
-rw-r--r--src/liballoc/boxed.rs4
-rw-r--r--src/librustdoc/html/static/playpen.js9
-rw-r--r--src/libstd/array.rs8
m---------src/rust-installer0
4 files changed, 14 insertions, 7 deletions
diff --git a/src/liballoc/boxed.rs b/src/liballoc/boxed.rs
index c941629b871..3dfd10f0916 100644
--- a/src/liballoc/boxed.rs
+++ b/src/liballoc/boxed.rs
@@ -71,7 +71,7 @@ use core::raw::{TraitObject};
 /// The following two examples are equivalent:
 ///
 /// ```
-/// # #![feature(box_heap)]
+/// #![feature(box_heap)]
 /// #![feature(box_syntax)]
 /// use std::boxed::HEAP;
 ///
@@ -162,7 +162,7 @@ impl<T : ?Sized> Box<T> {
 ///
 /// # Examples
 /// ```
-/// # #![feature(box_raw)]
+/// #![feature(box_raw)]
 /// use std::boxed;
 ///
 /// let seventeen = Box::new(17u32);
diff --git a/src/librustdoc/html/static/playpen.js b/src/librustdoc/html/static/playpen.js
index ff947d93fca..b7a5f202629 100644
--- a/src/librustdoc/html/static/playpen.js
+++ b/src/librustdoc/html/static/playpen.js
@@ -16,6 +16,7 @@ document.addEventListener('DOMContentLoaded', function() {
         return;
     }
 
+    var featureRegexp = new RegExp('^\s*#!\\[feature\\(\.*?\\)\\]');
     var elements = document.querySelectorAll('pre.rust');
 
     Array.prototype.forEach.call(elements, function(el) {
@@ -29,8 +30,14 @@ document.addEventListener('DOMContentLoaded', function() {
             a.setAttribute('class', 'test-arrow');
 
             var code = el.previousElementSibling.textContent;
+
+            var channel = '';
+            if (featureRegexp.test(code)) {
+                channel = '&version=nightly';
+            }
+
             a.setAttribute('href', window.playgroundUrl + '?code=' +
-                           encodeURIComponent(code));
+                           encodeURIComponent(code) + channel);
             a.setAttribute('target', '_blank');
 
             el.appendChild(a);
diff --git a/src/libstd/array.rs b/src/libstd/array.rs
index e79e5d5a680..0dfcc72e379 100644
--- a/src/libstd/array.rs
+++ b/src/libstd/array.rs
@@ -9,7 +9,7 @@
 // except according to those terms.
 
 //! A fixed-size array is denoted `[T; N]` for the element type `T` and
-//! the compile time constant size `N`. The size should be zero or positive.
+//! the compile time constant size `N`. The size must be zero or positive.
 //!
 //! Arrays values are created either with an explicit expression that lists
 //! each element: `[x, y, z]` or a repeat expression: `[x; N]`. The repeat
@@ -32,7 +32,9 @@
 //!
 //! [slice]: primitive.slice.html
 //!
-//! ## Examples
+//! Rust does not currently support generics over the size of an array type.
+//!
+//! # Examples
 //!
 //! ```
 //! let mut array: [i32; 3] = [0; 3];
@@ -49,7 +51,5 @@
 //!
 //! ```
 //!
-//! Rust does not currently support generics over the size of an array type.
-//!
 
 #![doc(primitive = "array")]
diff --git a/src/rust-installer b/src/rust-installer
-Subproject 0da191a30ba385215c5eb1dc97c2b5f076f93b0
+Subproject c37d3747da75c280237dc2d6b925078e6955549