') + ')', 'gi'); if (regex.test(text)) { found = true; var frag = document.createDocumentFragment(); var parts = text.split(regex); parts.forEach(function(part, i) { if (i % 2 === 0) { frag.appendChild(document.createTextNode(part)); } else { var span = document.createElement('span'); span.className = 'userscript-highlight'; span.textContent = part; frag.appendChild(span); } }); node.parentNode.replaceChild(frag, node); } }); } else if (node.nodeType === 1 && node.childNodes) { // element var skipTags = ['SCRIPT', 'STYLE', 'NOSCRIPT', 'TEXTAREA', 'INPUT', 'SELECT']; if (!skipTags.includes(node.tagName)) { Array.from(node.childNodes).forEach(highlight); } } } highlight(document.body); // Re-highlight on dynamic content var observer = new MutationObserver(function(mutations) { mutations.forEach(function(m) { m.addedNodes.forEach(function(node) { if (node.nodeType === 1 || node.nodeType === 3) highlight(node); }); }); }); observer.observe(document.body, { childList: true, subtree: true }); })(); } } catch(__e) { console.warn('[Userscript:Highlight Search Terms]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + ', 'i'); if (__m === '*' || __re.test(location.href)) { // Strip utm_, fbclid, gclid, etc. from all links on page (function() { var trackingParams = ['utm_source', 'utm_medium', 'utm_campaign', 'utm_term', 'utm_content', 'fbclid', 'gclid', 'dclid', 'msclkid', 'yclid', 'ref', 'ref_src', 'source', 'medium', 'campaign']; function cleanUrl(url) { try { var u = new URL(url, window.location.origin); var changed = false; trackingParams.forEach(function(p) { if (u.searchParams.has(p)) { u.searchParams.delete(p); changed = true; } }); return changed ? u.toString() : url; } catch (e) { return url; } } function cleanLinks() { document.querySelectorAll('a[href]').forEach(function(a) { var clean = cleanUrl(a.href); if (clean !== a.href) a.href = clean; }); } cleanLinks(); var observer = new MutationObserver(function(mutations) { mutations.forEach(function(m) { m.addedNodes.forEach(function(node) { if (node.nodeType === 1) { if (node.tagName === 'A') cleanLinks(); node.querySelectorAll('a[href]').forEach(function(a) { var clean = cleanUrl(a.href); if (clean !== a.href) a.href = clean; }); } }); }); }); observer.observe(document.body, { childList: true, subtree: true }); })(); } } catch(__e) { console.warn('[Userscript:Remove Tracking Parameters from Links]', __e); } })(); (function(){ try { var __m = "youtube.com"; var __re = new RegExp('^' + "youtube\\.com" + ', 'i'); if (__m === '*' || __re.test(location.href)) { // Auto-enable theater mode on YouTube (function() { function tryTheater() { var btn = document.querySelector('button[aria-label="Theater mode"], ytd-player #player button[title="Theater mode"]'); if (btn && !btn.classList.contains('activated')) { btn.click(); } } // Try immediately tryTheater(); // Try after navigation (SPA) var lastUrl = location.href; setInterval(function() { if (location.href !== lastUrl) { lastUrl = location.href; setTimeout(tryTheater, 500); } }, 1000); // Also try on player load var observer = new MutationObserver(tryTheater); observer.observe(document.body, { childList: true, subtree: true }); })(); } } catch(__e) { console.warn('[Userscript:YouTube Theater Mode Default]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + ', 'i'); if (__m === '*' || __re.test(location.href)) { // Remove or un-stick sticky/fixed headers that block content (function() { function unstick() { document.querySelectorAll('header, nav, [role="banner"], .header, .navbar, .sticky, .fixed-top, [style*="position: fixed"], [style*="position:sticky"]').forEach(function(el) { if (el.style.position === 'fixed' || el.style.position === 'sticky' || getComputedStyle(el).position === 'fixed' || getComputedStyle(el).position === 'sticky') { el.style.position = 'static'; el.style.top = 'auto'; el.style.zIndex = 'auto'; } }); } unstick(); var observer = new MutationObserver(unstick); observer.observe(document.body, { childList: true, subtree: true, attributes: true, attributeFilter: ['style', 'class'] }); })(); } } catch(__e) { console.warn('[Userscript:Kill Sticky Headers]', __e); } })(); })(); Rollup of 7 pull requests by Manishearth · Pull Request #33204 · rust-lang/rust · GitHub
Skip to content

Rollup of 7 pull requests - #33204

Merged
bors merged 16 commits into
rust-lang:masterfrom
Manishearth:rollup
Apr 26, 2016
Merged

Rollup of 7 pull requests#33204
bors merged 16 commits into
rust-lang:masterfrom
Manishearth:rollup

Conversation

sanxiynand others added 16 commits April 20, 2016 22:00
…esses
Signed-off-by: benaryorg <binary@benary.org>
This used to be done to avoid inlining impls referencing private items,
but is now unnecessary since we actually check that impls do not
reference non-doc-reachable items.
An item is inlined and recorded as inlined even if it is
`doc(hidden)`, leading to unchecked external links.
Show previous definition of duplicate impl item
Fixrust-lang#32971.
…ichton
rustdoc: inline all the impls
This used to be done to avoid inlining impls referencing private items, but is now unnecessary since we actually check that impls do not reference non-doc-reachable items.
fixesrust-lang#32881fixesrust-lang#33025fixesrust-lang#33113
r? @alexcrichton
… r=alexcrichton
show unstable status for deprecated items
Fixesrust-lang#32374.
clarify documentation of TcpStream::connect() for multiple valid addresses
I am not sure how the UDP part of the stdlib behaves when passing multiple valid addresses, but it should be mentioned as there are legit use cases for [`impl<'a> ToSocketAddrs for &'a [SocketAddr]`](http://doc.rust-lang.org/nightly/std/net/trait.ToSocketAddrs.html), a TCP fallback only being one.
Just a little example program for anyone willing to enhance the documentation further:
```rust
use std::net::SocketAddr;
use std::net::ToSocketAddrs;
use std::net::TcpStream;
fn main()
{
let v: Vec<SocketAddr> = vec!
[
"127.0.0.1:1338".to_socket_addrs().unwrap().next().unwrap(),
"127.0.0.1:1337".to_socket_addrs().unwrap().next().unwrap(),
"127.0.0.1:1339".to_socket_addrs().unwrap().next().unwrap(),
];
let stream = TcpStream::connect(&v[..]).unwrap();
}
```
@Manishearth

Copy link
Copy Markdown
MemberAuthor

@bors r+ p=10

@bors

bors commented Apr 25, 2016

Copy link
Copy Markdown
Collaborator

📌 Commit 3dc0b55 has been approved by Manishearth

@bors

bors commented Apr 25, 2016

Copy link
Copy Markdown
Collaborator

⌛ Testing commit 3dc0b55 with merge 149cf77...

bors added a commit that referenced this pull request Apr 25, 2016
Rollup of 7 pull requests
- Successful merges: #33107, #33133, #33160, #33167, #33194, #33196, #33200
- Failed merges:
@bors

bors commented Apr 25, 2016

Copy link
Copy Markdown
Collaborator

💔 Test failed - auto-win-msvc-32-opt

@alexcrichton

Copy link
Copy Markdown
Member

@bors: retry

On Mon, Apr 25, 2016 at 3:25 PM, bors notifications@github.com wrote:

[image: 💔] Test failed - auto-win-msvc-32-opt
http://buildbot.rust-lang.org/builders/auto-win-msvc-32-opt/builds/3164


You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub
#33204 (comment)

@Manishearth

Copy link
Copy Markdown
MemberAuthor

@bors force

@bors

bors commented Apr 26, 2016

Copy link
Copy Markdown
Collaborator

💔 Test failed - auto-linux-64-x-android-t

@Manishearth

Copy link
Copy Markdown
MemberAuthor

@bors retry force

looks like gdb went boom?

@Manishearth

Copy link
Copy Markdown
MemberAuthor

@bors retry force

@bors

bors commented Apr 26, 2016

Copy link
Copy Markdown
Collaborator

💔 Test failed - auto-linux-64-x-android-t

@Manishearth

Copy link
Copy Markdown
MemberAuthor

@bors retry p=9

@bors

bors commented Apr 26, 2016

Copy link
Copy Markdown
Collaborator

⌛ Testing commit 3dc0b55 with merge 41028de...

bors added a commit that referenced this pull request Apr 26, 2016
Rollup of 7 pull requests
- Successful merges: #33107, #33133, #33160, #33167, #33194, #33196, #33200
- Failed merges:
@bors
bors merged commit 3dc0b55 into rust-lang:masterApr 26, 2016
@CentrilCentril added the rollup A PR which is a rollup label Oct 2, 2019
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

rollupA PR which is a rollup

Projects

None yet

Development

Successfully merging this pull request may close these issues.

10 participants

@Manishearth@bors@alexcrichton@emberian@Centril@sanxiyn@euclio@benaryorg@mitaa@sfackler