package zapjournal

import (
	
	
	
)

// strconvAppendComplex is an append-style function for strconv.FormatComplex
// that is missing in the standard library.
func ( []byte,  complex128,  byte, ,  int) []byte {
	if  != 64 &&  != 128 {
		panic("invalid bitSize")
	}
	 >>= 1

	 = append(, '(')
	 = strconv.AppendFloat(, real(), , , )

	 := imag()
	if math.IsNaN() || (!math.IsInf(, 0) &&  > 0) {
		 = append(, '+')
	}

	 = strconv.AppendFloat(, , , , )
	 = append(, 'i', ')')
	return 
}

// strconvAppendUintptr is an append-style convenience function for uintptr
// values and strconv.AppendUint.
func ( []byte,  uintptr) []byte {
	 = append(, []byte("0x")...)
	 = strconv.AppendUint(, uint64(), 16)
	return 
}

// base64Append is an append-style function for base64 encoding.
//
// See also https://go.dev/issue/19366
func ( *base64.Encoding, ,  []byte) []byte {
	 := len()
	 := .EncodedLen(len())
	if cap()- <  {
		 = append(, make([]byte, )...)
	} else {
		 = [:+]
	}
	.Encode([:], )
	return 
}