summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorTristan Bruns <tristan+git@tristanbruns.de>2017-03-05 14:21:24 +0100
committerTristan Bruns <tristan+git@tristanbruns.de>2017-03-05 14:35:51 +0100
commit4f1e3da8502100c63e9708107a9a13e77ca86f11 (patch)
tree07f98009d881178c020c97025dae9b49a2406f36 /src
parent6320ed2514d93fdbbd429a6d67ee9e8bfdfcb297 (diff)
Use c_schar instead of c_char
The signedness of the C type 'char' is implementation defined. The rust type c_schar exists for this reason. Use it.
Diffstat (limited to 'src')
-rw-r--r--src/codegen/mod.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/codegen/mod.rs b/src/codegen/mod.rs
index fb07eaf8..77941fa3 100644
--- a/src/codegen/mod.rs
+++ b/src/codegen/mod.rs
@@ -2138,7 +2138,7 @@ impl ToRustTy for Type {
TypeKind::Int(ik) => {
match ik {
IntKind::Bool => aster::ty::TyBuilder::new().bool(),
- IntKind::Char => raw_type(ctx, "c_char"),
+ IntKind::Char => raw_type(ctx, "c_schar"),
IntKind::UChar => raw_type(ctx, "c_uchar"),
IntKind::Short => raw_type(ctx, "c_short"),
IntKind::UShort => raw_type(ctx, "c_ushort"),