joao-r-reis commented on code in PR #1915:
URL:
https://github.com/apache/cassandra-gocql-driver/pull/1915#discussion_r2459923607
##########
logger.go:
##########
@@ -222,6 +222,13 @@ type LogField struct {
Value LogFieldValue
}
+// NewLogField creates a new LogField with the given name and value. Currently
+// supports the following types: string, int, bool, fmt.Stringer, error,
net.IP.
+// If the type is not supported, it'll use the fmt package to print the value.
+func NewLogField(name string, value interface{}) LogField {
Review Comment:
I believe the boxing will result in extra allocs, We should just make the
private methods public (`newLogField`, `newLogFieldAny`, etc.)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]