@@ -59,7 +59,7 @@ public struct CLTLogger : LogHandler {
5959 Newlines in the metadata themselves are always replaced by \n (and other special characters are escaped too).
6060
6161 For now there is no option to allow multilines metadata. */
62- public enum MultilineMode {
62+ public enum MultilineMode : Sendable {
6363 /**
6464 The new lines in logs are replaced by the given value, the metadata are printed on the same line as the log.
6565
@@ -228,7 +228,7 @@ public struct CLTLogger : LogHandler {
228228 /* Do _not_ use os_unfair_lock, apparently it is bad in Swift:
229229 * <https://twitter.com/grynspan/status/1392080373752995849>.
230230 * There is OSAllocatedUnfairLock which exists and is good, but is also not available on Linux. */
231- private static var lock = NSLock ( )
231+ private static let lock = NSLock ( )
232232
233233 private var flatMetadataCache = [ String] ( )
234234
@@ -237,7 +237,7 @@ public struct CLTLogger : LogHandler {
237237
238238public extension CLTLogger {
239239
240- static var defaultConstantsByLogLevelForText : [ Logger . Level : Constants ] = {
240+ static let defaultConstantsByLogLevelForText : [ Logger . Level : Constants ] = {
241241 func addMeta( _ str: String ) -> Constants {
242242 let len1 = str. count - 2
243243 let len2 = str. trimmingCharacters ( in: . init( charactersIn: " []* " ) ) . count
@@ -302,7 +302,7 @@ public extension CLTLogger {
302302 }
303303
304304 /* Terminal does not support RGB colors, so we use 255-color palette. */
305- static var defaultConstantsByLogLevelForColors : [ Logger . Level : Constants ] = {
305+ static let defaultConstantsByLogLevelForColors : [ Logger . Level : Constants ] = {
306306 func str( _ spaces: String , _ str: String , _ mods1: [ SGR . Modifier ] , _ mods2: [ SGR . Modifier ] ) -> Constants {
307307 let bgColor = SGR . Modifier. reset
308308 let fgColor = SGR . Modifier. fgColorTo4BitBrightBlack
0 commit comments