diff options
author | Bernhard Schommer <bernhardschommer@gmail.com> | 2015-09-30 12:43:49 +0200 |
---|---|---|
committer | Bernhard Schommer <bernhardschommer@gmail.com> | 2015-09-30 12:43:49 +0200 |
commit | ee76d81e0e7d8a76cd31bf0d01a532d248dca45a (patch) | |
tree | fdce17a2651794b76c7958ccdf2029bc3e6dcfff /powerpc/Asmexpand.ml | |
parent | c0757aa180c54ff61093e8079ef58b77775ba28e (diff) | |
download | compcert-ee76d81e0e7d8a76cd31bf0d01a532d248dca45a.tar.gz compcert-ee76d81e0e7d8a76cd31bf0d01a532d248dca45a.zip |
Fixed minor issue with parameters that get put on the stack, made
the code more robust and added indentation for convertCompositeDef
Diffstat (limited to 'powerpc/Asmexpand.ml')
-rw-r--r-- | powerpc/Asmexpand.ml | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/powerpc/Asmexpand.ml b/powerpc/Asmexpand.ml index 80aa333e..050380ae 100644 --- a/powerpc/Asmexpand.ml +++ b/powerpc/Asmexpand.ml @@ -615,7 +615,7 @@ let preg_to_dwarf_int = function | _ -> assert false -let translate_annot a = +let translate_annot annot = let rec aux = function | BA x -> Some (BA (preg_to_dwarf_int x)) | BA_int _ @@ -632,7 +632,9 @@ let translate_annot a = | Some hi ,Some lo -> Some (BA_splitlong (hi,lo)) | _,_ -> None end in - aux (List.hd a) + (match annot with + | [] -> None + | a::_ -> aux a) let expand_scope id lbl oldscopes newscopes = let opening = List.filter (fun a -> not (List.mem a oldscopes)) newscopes |