From 83f553cd89f207549476b2b1aa1e600166748edd Mon Sep 17 00:00:00 2001 From: Mikkel Hjortshoej Date: Thu, 2 Jul 2020 16:11:41 +0200 Subject: [PATCH] Revert to old format and fix : when no file opt specified --- core/log/file_console_logger.odin | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/core/log/file_console_logger.odin b/core/log/file_console_logger.odin index 50632a64d..56e3e6c80 100644 --- a/core/log/file_console_logger.odin +++ b/core/log/file_console_logger.odin @@ -127,20 +127,19 @@ do_location_header :: proc(opts: Options, buf: ^strings.Builder, location := #ca if Location_File_Opts & opts != nil { fmt.sbprint(buf, file); } - - if .Procedure in opts { - if Location_File_Opts & opts != nil { - fmt.sbprint(buf, ":"); - } - fmt.sbprintf(buf, "%s()", location.procedure); - } - if .Line in opts { - if (Location_File_Opts | {.Procedure}) & opts != nil { + if Location_File_Opts & opts != nil { fmt.sbprint(buf, ":"); } fmt.sbprint(buf, location.line); } + if .Procedure in opts { + if (Location_File_Opts | {.Procedure}) & opts != nil { + fmt.sbprint(buf, ":"); + } + fmt.sbprintf(buf, "%s()", location.procedure); + } + fmt.sbprint(buf, "] "); }