Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add generic ptr.To, ptr.Deref, ptr.Equal
This simplifies the implementation and adds support for pointers to enums and arbitrary types. To allow a complete migration from pointer to ptr, this also moves AllPtrFieldsNil. The ptr.AllPtrFieldsNil "ptr" repetition is preserved since the function only looks at pointer fields. Existing deprecation notices are updated to point to the new functions, and the pointer package as a whole is deprecated. Existing test code is preserved as-is to "prove" the correctness of the migration. This was mostly written by Aldo Culquicondor; see #269 for context. Signed-off-by: Stephen Kitt <skitt@redhat.com>
- Loading branch information