Skip to content

Commit

Permalink
Auto merge of #26961 - Manishearth:rollup, r=Manishearth
Browse files Browse the repository at this point in the history
- Successful merges: #26932, #26936, #26943, #26944
- Failed merges:
  • Loading branch information
bors committed Jul 11, 2015
2 parents f7f28c8 + 25b1437 commit 1b28ffa
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 8 deletions.
4 changes: 2 additions & 2 deletions src/liballoc/boxed.rs
Expand Up @@ -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;
///
Expand Down Expand Up @@ -162,7 +162,7 @@ impl<T : ?Sized> Box<T> {
///
/// # Examples
/// ```
/// # #![feature(box_raw)]
/// #![feature(box_raw)]
/// use std::boxed;
///
/// let seventeen = Box::new(17u32);
Expand Down
9 changes: 8 additions & 1 deletion src/librustdoc/html/static/playpen.js
Expand Up @@ -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) {
Expand All @@ -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);
Expand Down
8 changes: 4 additions & 4 deletions src/libstd/array.rs
Expand Up @@ -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
Expand All @@ -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];
Expand All @@ -49,7 +51,5 @@
//!
//! ```
//!
//! Rust does not currently support generics over the size of an array type.
//!

#![doc(primitive = "array")]
2 changes: 1 addition & 1 deletion src/rust-installer

0 comments on commit 1b28ffa

Please sign in to comment.