Float32 constructs a field that carries a float32. The way the floating-point value is represented is encoder-dependent, so marshaling is necessarily lazy.
(key string, val float32)
| 136 | // floating-point value is represented is encoder-dependent, so marshaling is |
| 137 | // necessarily lazy. |
| 138 | func Float32(key string, val float32) Field { |
| 139 | return Field{Key: key, Type: zapcore.Float32Type, Integer: int64(math.Float32bits(val))} |
| 140 | } |
| 141 | |
| 142 | // Float32p constructs a field that carries a *float32. The returned Field will safely |
| 143 | // and explicitly represent `nil` when appropriate. |
no outgoing calls