Open pentateu opened 5 years ago
Added DisableFunctionTypePointerAddresses to config.
If true it will not print the address of a Func field.
Example: type someFuncType func(string) string type someStructType struct { funcField someFuncType }
before this PR this would print: (*spew_test.ptrFuncTester)({ funcField: (spew_test.someFuncType) 0x11a49b0 })
With this PR and DisableFunctionTypePointerAddresses = true it will print: (*spew_test.ptrFuncTester)({ funcField: (spew_test.someFuncType) })
This is important for snapshot testing, which is my use case.
Cheers
Added DisableFunctionTypePointerAddresses to config.
If true it will not print the address of a Func field.
Example: type someFuncType func(string) string type someStructType struct { funcField someFuncType }
before this PR this would print: (*spew_test.ptrFuncTester)({ funcField: (spew_test.someFuncType) 0x11a49b0 })
With this PR and DisableFunctionTypePointerAddresses = true it will print: (*spew_test.ptrFuncTester)({ funcField: (spew_test.someFuncType)
})
This is important for snapshot testing, which is my use case.
Cheers