Implement more type kinds
This commit is contained in:
parent
ab7d138d16
commit
89ee0f997c
12
src/type_.rs
12
src/type_.rs
@ -170,9 +170,19 @@ fn type_kind(&self, typ: Type<'gcc>) -> TypeKind {
|
|||||||
TypeKind::Double
|
TypeKind::Double
|
||||||
} else if typ.is_vector() {
|
} else if typ.is_vector() {
|
||||||
TypeKind::Vector
|
TypeKind::Vector
|
||||||
|
} else if typ.get_pointee().is_some() {
|
||||||
|
TypeKind::Pointer
|
||||||
|
} else if typ.dyncast_array().is_some() {
|
||||||
|
TypeKind::Array
|
||||||
|
} else if typ.is_struct().is_some() {
|
||||||
|
TypeKind::Struct
|
||||||
|
} else if typ.dyncast_function_ptr_type().is_some() {
|
||||||
|
TypeKind::Function
|
||||||
|
} else if typ == self.type_void() {
|
||||||
|
TypeKind::Void
|
||||||
} else {
|
} else {
|
||||||
// TODO(antoyo): support other types.
|
// TODO(antoyo): support other types.
|
||||||
TypeKind::Void
|
unimplemented!();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -36,7 +36,6 @@ tests/ui/parser/unclosed-delimiter-in-dep.rs
|
|||||||
tests/ui/simd/intrinsic/ptr-cast.rs
|
tests/ui/simd/intrinsic/ptr-cast.rs
|
||||||
tests/ui/consts/missing_span_in_backtrace.rs
|
tests/ui/consts/missing_span_in_backtrace.rs
|
||||||
tests/ui/drop/dynamic-drop.rs
|
tests/ui/drop/dynamic-drop.rs
|
||||||
tests/ui/dyn-star/box.rs
|
|
||||||
tests/ui/issues/issue-40883.rs
|
tests/ui/issues/issue-40883.rs
|
||||||
tests/ui/issues/issue-43853.rs
|
tests/ui/issues/issue-43853.rs
|
||||||
tests/ui/issues/issue-47364.rs
|
tests/ui/issues/issue-47364.rs
|
||||||
|
Loading…
Reference in New Issue
Block a user