Cactuses can be spawned next to blocks (e.g. during village generation.) This bug is recorded as MC-4120, currently marked as invalid, even though if such generation glitches are considered a feature it should probably be marked as 'Works as Intended'.
But when such a cactus spawns, you can see through it from certain angles, as per this screenshot. So, either cactuses spawning next to solid blocks should be fixed, or the graphical glitch I see should be corrected.
Marking this as a duplicate of MC-86 and reopening it.