|
|
@@ -154,7 +154,7 @@ let rec print_assembly oc instrs =
|
|
|
(* Directives (lines beginning with a '.') are collected in endbuf and are
|
|
|
* printed at the end of the file here. The directives are sorted by the first
|
|
|
* 7 characters to group directive opcodes *)
|
|
|
- if List.length !endbuf > 1 then begin
|
|
|
+ if List.length !endbuf > 0 then begin
|
|
|
output_line (instr2str (Comment ("globals:")));
|
|
|
let cmp a b = compare (String.sub b 0 7) (String.sub a 0 7) in
|
|
|
List.iter output_line (List.sort cmp (List.rev !endbuf))
|