The reported data is indeed sometimes tricky to use, but the comment is not completely true. In order to see if a raycast reaches the destination, one should check that the landing poly is the one where the destination lies. Or in some cases adjacent to the destination poly. The functions origins is in game logic where you'd like to know "can I move to this direction 5 meters", where the exact goal location is not necessary.
It might make sense to have separate functions for these two cases, or add a flag which specifies which use case you'd like (maybe the first is subset of the second?)