@@ -152,7 +152,7 @@ and gen_class f g clas targetdir =
152
152
153
153
154
154
and gen_enum f g targetdir = function
155
- | Enum (name , _ , contents ) ->
155
+ | Enum (name , contents ) ->
156
156
if not (List. mem name ! all_headers) then
157
157
all_headers := name::! all_headers;
158
158
let out_chan = open_out (Filename. concat targetdir (g name))
@@ -502,7 +502,7 @@ and abstract_result_handling needed classname msg_name param_count = function
502
502
return session->ok;
503
503
" record_tn (initialiser_of_ty (Record n)) call
504
504
505
- | Enum (e , _ , _ ) ->
505
+ | Enum (e , _ ) ->
506
506
sprintf
507
507
" %s
508
508
%s
@@ -545,7 +545,7 @@ and abstract_result_type typ =
545
545
546
546
and abstract_type record = function
547
547
| String -> " abstract_type_string"
548
- | Enum (n , _ , _ ) ->
548
+ | Enum (n , _ ) ->
549
549
sprintf " %s_abstract_type_" (typename n)
550
550
| Ref _ ->
551
551
if record then
@@ -556,7 +556,7 @@ and abstract_type record = function
556
556
| Float -> " abstract_type_float"
557
557
| Bool -> " abstract_type_bool"
558
558
| DateTime -> " abstract_type_datetime"
559
- | Set (Enum(n , _ , _ )) ->
559
+ | Set (Enum(n , _ )) ->
560
560
sprintf " %s_set_abstract_type_" (typename n)
561
561
| Set (Record "event" ) ->
562
562
" xen_event_record_set_abstract_type_"
@@ -569,8 +569,8 @@ and abstract_type record = function
569
569
sprintf " abstract_type_%s_ref_map" (name_of_ty l)
570
570
else
571
571
sprintf " abstract_type_%s_string_map" (name_of_ty l)
572
- | Map ((Enum(_ ,_ , _ ) as l ), r ) -> (mapname l r) ^ " _abstract_type_"
573
- | Map (l , (Enum(_ ,_ , _ ) as r )) -> (mapname l r) ^ " _abstract_type_"
572
+ | Map ((Enum(_ ,_ ) as l ), r ) -> (mapname l r) ^ " _abstract_type_"
573
+ | Map (l , (Enum(_ ,_ ) as r )) -> (mapname l r) ^ " _abstract_type_"
574
574
| Map (l , r ) -> sprintf " abstract_type_" ^ (mapname l r)
575
575
576
576
| Record n -> sprintf " %s_abstract_type_" (record_typename n)
923
923
924
924
begin
925
925
match l, r with
926
- (Enum(_ ,_ , _ ), _ ) -> gen_enum_map_abstract_type print name l r
927
- | (_ , Enum(_ ,_ , _ )) -> gen_enum_map_abstract_type print name l r
926
+ (Enum(_ , _ ), _ ) -> gen_enum_map_abstract_type print name l r
927
+ | (_ , Enum(_ , _ )) -> gen_enum_map_abstract_type print name l r
928
928
| _ -> ()
929
929
end
930
930
@@ -968,7 +968,7 @@ extern const abstract_type %s_abstract_type_;
968
968
969
969
970
970
and hash_include_enum = function
971
- Enum (x ,_ , _ ) ->
971
+ Enum (x , _ ) ->
972
972
" \n " ^ hash_include x
973
973
| _ ->
974
974
" "
@@ -1220,13 +1220,13 @@ and find_needed'' needed = function
1220
1220
| Float
1221
1221
| Bool
1222
1222
| DateTime -> ()
1223
- | Enum (n , _ , _ ) ->
1223
+ | Enum (n , _ ) ->
1224
1224
needed := StringSet. add (n ^ " _internal" ) ! needed
1225
1225
| Ref n ->
1226
1226
needed := StringSet. add n ! needed
1227
1227
| Set (Ref n ) ->
1228
1228
needed := StringSet. add n ! needed
1229
- | Set (Enum (e , _ , _ )) ->
1229
+ | Set (Enum (e , _ )) ->
1230
1230
needed := StringSet. add e ! needed;
1231
1231
needed := StringSet. add (e ^ " _internal" ) ! needed
1232
1232
| Set (Record "event" ) ->
@@ -1251,10 +1251,10 @@ and free_impl val_name record = function
1251
1251
| Float
1252
1252
| Bool
1253
1253
| DateTime
1254
- | Enum (_ , _ , _ ) -> " "
1254
+ | Enum (_ , _ ) -> " "
1255
1255
| Ref n -> sprintf " %s_free(%s);" (if record then record_opt_typename n else typename n) val_name
1256
1256
| Set (Ref n ) -> sprintf " %s_opt_set_free(%s);" (record_typename n) val_name
1257
- | Set (Enum (e ,_ , _ )) -> sprintf " %s_set_free(%s);" (typename e) val_name
1257
+ | Set (Enum (e , _ )) -> sprintf " %s_set_free(%s);" (typename e) val_name
1258
1258
| Set (String) -> sprintf " xen_string_set_free(%s);" val_name
1259
1259
| Map (l , r ) -> let n = mapname l r in
1260
1260
sprintf " %s_free(%s);" (typename n) val_name
@@ -1264,14 +1264,14 @@ and free_impl val_name record = function
1264
1264
1265
1265
1266
1266
and add_enum_internal needed = function
1267
- | Enum (x ,_ , _ ) -> StringSet. add (x ^ " _internal" ) needed
1268
- | _ -> needed
1267
+ | Enum (x , _ ) -> StringSet. add (x ^ " _internal" ) needed
1268
+ | _ -> needed
1269
1269
1270
1270
1271
1271
and add_enum_map_internal needed l r =
1272
1272
match (l, r) with
1273
- (Enum(_ ,_ , _ ), _ ) -> StringSet. add ((mapname l r) ^ " _internal" ) needed
1274
- | (_ , Enum(_ ,_ , _ )) -> StringSet. add ((mapname l r) ^ " _internal" ) needed
1273
+ (Enum(_ , _ ), _ ) -> StringSet. add ((mapname l r) ^ " _internal" ) needed
1274
+ | (_ , Enum(_ , _ )) -> StringSet. add ((mapname l r) ^ " _internal" ) needed
1275
1275
| _ -> needed
1276
1276
1277
1277
@@ -1288,7 +1288,7 @@ and c_type_of_ty needed record = function
1288
1288
sprintf " struct %s *" (record_opt_typename name)
1289
1289
else
1290
1290
sprintf " %s " (typename name)
1291
- | Enum (name , _ , cs ) as x ->
1291
+ | Enum (name , cs ) as x ->
1292
1292
needed := StringSet. add name ! needed;
1293
1293
enums := TypeSet. add x ! enums;
1294
1294
c_type_of_enum name
@@ -1298,7 +1298,7 @@ and c_type_of_ty needed record = function
1298
1298
sprintf " struct %s_set *" (record_opt_typename name)
1299
1299
else
1300
1300
sprintf " struct %s_set *" (typename name)
1301
- | Set (Enum (e ,_ , _ ) as x ) ->
1301
+ | Set (Enum (e , _ ) as x ) ->
1302
1302
let enum_typename = typename e in
1303
1303
needed := StringSet. add e ! needed;
1304
1304
enums := TypeSet. add x ! enums;
@@ -1317,8 +1317,8 @@ and c_type_of_ty needed record = function
1317
1317
maps := TypeSet. add x ! maps;
1318
1318
begin
1319
1319
match (l, r) with
1320
- (Enum(_ ,_ , _ ), _ ) -> enum_maps := TypeSet. add x ! enum_maps
1321
- | (_ , Enum(_ ,_ , _ )) -> enum_maps := TypeSet. add x ! enum_maps
1320
+ (Enum(_ , _ ), _ ) -> enum_maps := TypeSet. add x ! enum_maps
1321
+ | (_ , Enum(_ , _ )) -> enum_maps := TypeSet. add x ! enum_maps
1322
1322
| _ -> ()
1323
1323
end ;
1324
1324
sprintf " %s *" (typename n)
@@ -1351,7 +1351,7 @@ and name_of_ty = function
1351
1351
| Float -> " float"
1352
1352
| Bool -> " bool"
1353
1353
| DateTime -> " datetime"
1354
- | Enum (x ,_ , _ ) -> x
1354
+ | Enum (x , _ ) -> x
1355
1355
| Set (x ) -> sprintf " %s_set" (name_of_ty x)
1356
1356
| Ref (x ) -> x
1357
1357
| Map (l ,r ) -> sprintf " %s_%s_map" (name_of_ty l) (name_of_ty r)
0 commit comments