gingerBill 7 years ago
parent
commit
529d1c78c7
1 changed files with 1 additions and 1 deletions
  1. 1 1
      core/fmt.odin

+ 1 - 1
core/fmt.odin

@@ -938,7 +938,7 @@ fmt_value :: proc(fi: ^Fmt_Info, v: any, verb: rune) {
 		case: panic("Invalid union tag type");
 		case: panic("Invalid union tag type");
 		}
 		}
 
 
-		if data == nil || tag < 0 {
+		if data == nil || tag <= 0 {
 			write_string(fi.buf, "(union)");
 			write_string(fi.buf, "(union)");
 		} else {
 		} else {
 			ti := info.variants[tag-1];
 			ti := info.variants[tag-1];