Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rollup of 4 pull requests #46696

Merged
merged 8 commits into from
Dec 12, 2017
1 change: 1 addition & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
language: shell
sudo: required
dist: trusty
group: deprecated-2017Q4
services:
- docker

Expand Down
8 changes: 4 additions & 4 deletions src/librustdoc/html/static/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -911,24 +911,24 @@
searchWords[j].replace(/_/g, "").indexOf(val) > -1)
{
// filter type: ... queries
if (typePassesFilter(typeFilter, ty) && results[fullId] === undefined) {
if (typePassesFilter(typeFilter, ty.ty) && results[fullId] === undefined) {
index = searchWords[j].replace(/_/g, "").indexOf(val);
}
}
if ((lev = levenshtein(searchWords[j], val)) <= MAX_LEV_DISTANCE) {
if (typePassesFilter(typeFilter, ty) === false) {
if (typePassesFilter(typeFilter, ty.ty) === false) {
lev = MAX_LEV_DISTANCE + 1;
} else {
lev += 1;
}
}
if ((in_args = findArg(ty, valGenerics)) <= MAX_LEV_DISTANCE) {
if (typePassesFilter(typeFilter, ty) === false) {
if (typePassesFilter(typeFilter, ty.ty) === false) {
in_args = MAX_LEV_DISTANCE + 1;
}
}
if ((returned = checkReturned(ty, valGenerics)) <= MAX_LEV_DISTANCE) {
if (typePassesFilter(typeFilter, ty) === false) {
if (typePassesFilter(typeFilter, ty.ty) === false) {
returned = MAX_LEV_DISTANCE + 1;
}
}
Expand Down
18 changes: 14 additions & 4 deletions src/librustdoc/html/static/rustdoc.css
Original file line number Diff line number Diff line change
Expand Up @@ -822,6 +822,7 @@ span.since {
margin-left: -15px;
padding: 0 15px;
position: static;
z-index: 1;
}

.sidebar > .location {
Expand All @@ -848,25 +849,34 @@ span.since {
}

.sidebar-menu {
position: absolute;
position: fixed;
z-index: 10;
font-size: 2rem;
cursor: pointer;
margin-top: 2px;
width: 45px;
left: 0;
text-align: center;
display: block;
border-bottom: 1px solid;
border-right: 1px solid;
}

.sidebar-elems {
background-color: #F1F1F1;
position: fixed;
z-index: 1;
left: 0;
top: 45px;
bottom: 0;
overflow-y: auto;
border-right: 1px solid #000;
border-right: 1px solid;
display: none;
}

.sidebar > .block.version {
border-bottom: none;
margin-top: 12px;
}

nav.sub {
margin: 0 auto;
}
Expand Down
13 changes: 13 additions & 0 deletions src/librustdoc/html/static/styles/main.css
Original file line number Diff line number Diff line change
Expand Up @@ -330,3 +330,16 @@ pre.ignore:hover, .information:hover + pre.ignore {
.modal-content > .close:hover + .whiter {
background-color: #ff1f1f;
}

@media (max-width: 700px) {
.sidebar-menu {
background-color: #F1F1F1;
border-bottom-color: #e0e0e0;
border-right-color: #e0e0e0;
}

.sidebar-elems {
background-color: #F1F1F1;
border-right-color: #000;
}
}
4 changes: 2 additions & 2 deletions src/rustllvm/RustWrapper.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -566,8 +566,8 @@ extern "C" void LLVMRustAddModuleFlag(LLVMModuleRef M, const char *Name,
unwrap(M)->addModuleFlag(Module::Warning, Name, Value);
}

extern "C" void LLVMRustMetadataAsValue(LLVMContextRef C, LLVMMetadataRef MD) {
wrap(MetadataAsValue::get(*unwrap(C), unwrap(MD)));
extern "C" LLVMValueRef LLVMRustMetadataAsValue(LLVMContextRef C, LLVMMetadataRef MD) {
return wrap(MetadataAsValue::get(*unwrap(C), unwrap(MD)));
}

extern "C" LLVMRustDIBuilderRef LLVMRustDIBuilderCreate(LLVMModuleRef M) {
Expand Down