-
-
Notifications
You must be signed in to change notification settings - Fork 614
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
core:log improvements #4463
base: master
Are you sure you want to change the base?
core:log improvements #4463
Conversation
There were various issues with core:log, namely that it would silently use context.allocator behind your back. The api has been changed to allow the user to provide an interface to the creation of file/console logger and multiloggers. Furthermore updated the language used to be more consistent with odin's naming scheme. This renames create -> make and detroy -> delete. The old names and behaviour have been deprecated and have had their behaviour retained. Additionally support for os2 has been added.
Looks like test runner got stuck |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not a final review, I might have missed some obvious things in the docs.
@@ -6,8 +6,11 @@ import "core:encoding/ansi" | |||
import "core:fmt" | |||
import "core:strings" | |||
import "core:os" | |||
import "core:os/os2" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My issue with importing os2
here is that it doesn't support everything yet. You might have to split file_console_logger.odin
into two files. One for the platforms that support os2
, and one for everything else.
There were various issues with core:log, namely that it would silently use context.allocator behind your back. The api has been changed to allow the user to provide an interface to the creation of file/console logger and multiloggers.
Furthermore updated the language used to be more consistent with odin's naming scheme. This renames create -> make and detroy -> delete.
The old names and behaviour have been deprecated and have had their behaviour retained.
Additionally support for os2 has been added.
Documentation was added too.