@@ -29,7 +29,9 @@ impl FromStr for TypeKind {
29
29
match s {
30
30
"bfloat" => Ok ( Self :: BFloat ) ,
31
31
"float" => Ok ( Self :: Float ) ,
32
- "int" => Ok ( Self :: Int ( true ) ) ,
32
+ "double" => Ok ( Self :: Double ) ,
33
+ "int" | "long" => Ok ( Self :: Int ( true ) ) ,
34
+ "short" => Ok ( Self :: Short ( true ) ) ,
33
35
"poly" => Ok ( Self :: Poly ) ,
34
36
"char" => Ok ( Self :: Char ( true ) ) ,
35
37
"uint" | "unsigned" => Ok ( Self :: Int ( false ) ) ,
@@ -70,7 +72,6 @@ impl TypeKind {
70
72
Self :: Int ( false ) => "uint" ,
71
73
Self :: Poly => "poly" ,
72
74
Self :: Char ( true ) => "char" ,
73
- Self :: Char ( false ) => "unsigned char" ,
74
75
_ => unreachable ! ( "Not used: {:#?}" , self ) ,
75
76
}
76
77
}
@@ -143,15 +144,15 @@ impl IntrinsicType {
143
144
pub fn is_ptr ( & self ) -> bool {
144
145
self . ptr
145
146
}
146
-
147
+
147
148
pub fn set_bit_len ( & mut self , value : Option < u32 > ) {
148
149
self . bit_len = value;
149
150
}
150
-
151
+
151
152
pub fn set_simd_len ( & mut self , value : Option < u32 > ) {
152
153
self . simd_len = value;
153
154
}
154
-
155
+
155
156
pub fn set_vec_len ( & mut self , value : Option < u32 > ) {
156
157
self . vec_len = value;
157
158
}
@@ -209,7 +210,7 @@ impl IntrinsicType {
209
210
match self {
210
211
IntrinsicType {
211
212
bit_len : Some ( bit_len @ ( 8 | 16 | 32 | 64 ) ) ,
212
- kind : kind @ ( TypeKind :: Int ( _) | TypeKind :: Poly ) ,
213
+ kind : kind @ ( TypeKind :: Int ( _) | TypeKind :: Poly | TypeKind :: Char ( _ ) ) ,
213
214
simd_len,
214
215
vec_len,
215
216
..
0 commit comments