Documentation ¶
Overview ¶
Package areflect provides utilities to help with reflection.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ForceExport ¶
ForceExport returns a new reflect.Value that is identical to the one passed in argument except that it's considered as an exported symbol even if in reality it isn't.
The `reflect' package intentionally makes it impossible to access the value of an unexported attribute. The implementation of reflect.DeepEqual() cheats as it bypasses this check. Unfortunately, we can't use the same cheat, which prevents us from re-implementing DeepEqual properly or implementing some other reflection-based tools. So this is our cheat on top of theirs. It makes the given reflect.Value appear as if it was exported.
This function requires go1.6 or newer.
Types ¶
This section is empty.