When planning out a rail line through a forest, I ran into an issue where a particular tree is causing strange discrepancies. Basically the problem is that I can place a straight rail just fine if I do it manually or with the basic rail planner, but when using the ghost rail planner it doesn't think the tile is passable, and all I get is a red X unless I hold down shift.
Here we can see that a straight rail can be placed passing by the tree:

But I can't place a curved rail towards the tree...

And I ALSO can't place a curved rail facing away from the tree!

And when I use the ghost rail planner instead, it won't even plot the straight path!

Conclusion: Whatever method the ghost rail planner is using to detect collision is inconsistent with the one used for manual placement.
I probably shouldn't be allowed to place that horizontal rail at all. The first train coming through will probably hit it anyway.
Save file is here