Skip to content

Commit 1f130c1

Browse files
author
bors-servo
authored
Auto merge of #474 - emilio:buildfix, r=fitzgen
Don't break the build so fast for older rust versions.
2 parents 4f753df + 1228df6 commit 1f130c1

File tree

3 files changed

+16
-13
lines changed

3 files changed

+16
-13
lines changed

Cargo.lock

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ name = "bindgen"
1313
readme = "README.md"
1414
repository = "https://github.com/servo/rust-bindgen"
1515
documentation = "https://docs.rs/bindgen"
16-
version = "0.21.1"
16+
version = "0.21.2"
1717
build = "build.rs"
1818

1919
exclude = ["tests/headers", "tests/expectations"]

src/clang.rs

+14-11
Original file line numberDiff line numberDiff line change
@@ -1366,27 +1366,30 @@ pub fn ast_dump(c: &Cursor, depth: isize) -> CXChildVisitResult {
13661366

13671367
if let Some(refd) = c.referenced() {
13681368
if refd != *c {
1369-
println!();
1369+
println!("");
13701370
print_cursor(depth,
13711371
String::from(prefix) + "referenced.",
13721372
&refd);
1373+
print_cursor(depth, String::from(prefix) + "referenced.", &refd);
13731374
}
13741375
}
13751376

13761377
let canonical = c.canonical();
13771378
if canonical != *c {
1378-
println!();
1379+
println!("");
13791380
print_cursor(depth,
13801381
String::from(prefix) + "canonical.",
13811382
&canonical);
1383+
print_cursor(depth, String::from(prefix) + "canonical.", &canonical);
13821384
}
13831385

13841386
if let Some(specialized) = c.specialized() {
13851387
if specialized != *c {
1386-
println!();
1388+
println!("");
13871389
print_cursor(depth,
13881390
String::from(prefix) + "specialized.",
13891391
&specialized);
1392+
print_cursor(depth, String::from(prefix) + "specialized.", &specialized);
13901393
}
13911394
}
13921395
}
@@ -1419,56 +1422,56 @@ pub fn ast_dump(c: &Cursor, depth: isize) -> CXChildVisitResult {
14191422

14201423
let canonical = ty.canonical_type();
14211424
if canonical != *ty {
1422-
println!();
1425+
println!("");
14231426
print_type(depth, String::from(prefix) + "canonical.", &canonical);
14241427
}
14251428

14261429
if let Some(pointee) = ty.pointee_type() {
14271430
if pointee != *ty {
1428-
println!();
1431+
println!("");
14291432
print_type(depth, String::from(prefix) + "pointee.", &pointee);
14301433
}
14311434
}
14321435

14331436
if let Some(elem) = ty.elem_type() {
14341437
if elem != *ty {
1435-
println!();
1438+
println!("");
14361439
print_type(depth, String::from(prefix) + "elements.", &elem);
14371440
}
14381441
}
14391442

14401443
if let Some(ret) = ty.ret_type() {
14411444
if ret != *ty {
1442-
println!();
1445+
println!("");
14431446
print_type(depth, String::from(prefix) + "return.", &ret);
14441447
}
14451448
}
14461449

14471450
let named = ty.named();
14481451
if named != *ty && named.is_valid() {
1449-
println!();
1452+
println!("");
14501453
print_type(depth, String::from(prefix) + "named.", &named);
14511454
}
14521455
}
14531456

14541457
print_indent(depth, "(");
14551458
print_cursor(depth, "", c);
14561459

1457-
println!();
1460+
println!("");
14581461
let ty = c.cur_type();
14591462
print_type(depth, "type.", &ty);
14601463

14611464
let declaration = ty.declaration();
14621465
if declaration != *c && declaration.kind() != CXCursor_NoDeclFound {
1463-
println!();
1466+
println!("");
14641467
print_cursor(depth, "type.declaration.", &declaration);
14651468
}
14661469

14671470
// Recurse.
14681471
let mut found_children = false;
14691472
c.visit(|s| {
14701473
if !found_children {
1471-
println!();
1474+
println!("");
14721475
found_children = true;
14731476
}
14741477
ast_dump(&s, depth + 1)

0 commit comments

Comments
 (0)