Skip to content

Commit a1ad6ed

Browse files
committed
squash! Update quasi, aster and syntex, remove nasty include! hack.
This is why I'm so happy with the move to aster, only one extra line of code change.
1 parent 33e3f78 commit a1ad6ed

File tree

2 files changed

+11
-15
lines changed

2 files changed

+11
-15
lines changed

Cargo.toml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,24 +23,24 @@ quasi_codegen = "0.15"
2323

2424
[dependencies]
2525
clang-sys = "0.8.0"
26-
libc = "0.2.*"
27-
log = "0.3.*"
28-
env_logger = "*"
26+
libc = "0.2"
27+
log = "0.3"
28+
env_logger = "0.3"
2929
rustc-serialize = "0.3.19"
30-
syntex_syntax = "0.38"
30+
syntex_syntax = "0.43"
3131
regex = "0.1"
3232

3333
[dependencies.aster]
3434
features = ["with-syntex"]
35-
version = "0.21.1"
35+
version = "0.26"
3636

3737
[dependencies.clippy]
3838
optional = true
3939
version = "*"
4040

4141
[dependencies.quasi]
4242
features = ["with-syntex"]
43-
version = "0.15"
43+
version = "0.19"
4444

4545
[features]
4646
llvm_stable = []

src/codegen/mod.rs

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
mod helpers;
2+
3+
use self::helpers::{attributes, ArrayTyBuilder, BlobTyBuilder};
4+
15
use ir::context::BindgenContext;
26
use ir::item::{Item, ItemId, ItemCanonicalName, ItemCanonicalPath};
37
use ir::ty::{Type, TypeKind};
@@ -23,14 +27,6 @@ use syntax::codemap::{Span, respan};
2327
use syntax::ptr::P;
2428
use aster;
2529

26-
// FIXME: This is shame, but we need to do this here since quasi eats the
27-
// includes in the "helpers" mod otherwise.
28-
mod helpers {
29-
include!("helpers.rs");
30-
}
31-
32-
use self::helpers::{attributes, ArrayTyBuilder, BlobTyBuilder};
33-
3430
fn root_import(ctx: &BindgenContext) -> P<ast::Item> {
3531
assert!(ctx.options().enable_cxx_namespaces, "Somebody messed it up");
3632
let root = ctx.root_module().canonical_name(ctx);
@@ -1060,7 +1056,7 @@ impl MethodCodegen for Method {
10601056
abi: Abi::Rust,
10611057
decl: P(fndecl.clone()),
10621058
generics: ast::Generics::default(),
1063-
constness: ast::Constness::NotConst,
1059+
constness: respan(ctx.span(), ast::Constness::NotConst),
10641060
};
10651061

10661062
// TODO: We need to keep in sync the argument names, so we should unify

0 commit comments

Comments
 (0)