I have a TO 35 that has that happen on occasion if I shift too fast. It will do it in reverse at times too. Two ways to correct it both pretty simple. As Billrog says, pull the oil filler cap and try sliding the gears a bit back and forth until something moves, or (this way is easier) lift the rubber boot at the base of the shift lever, push out the little round pin that goes sideways through the shift mechanism (be careful not to drop to the ground and loose it), Lift the shift lever up, reinsert the lever into what ever gear it is supposed to be and shift it back to neutral, re-insert the pin. I carry a small #1 phillips in the tool box to use as a drift to push the pin out. Once you get used to doing it, it is about a 30 second fix. Might take a hammer to tap the pin out he first few times you do it (Not usually though, usually you can just tap the screw driver lightly with the palm of you hand to push the pin out)
I have heard of people fixing it permanently by adding a little weld spot to the ball on the business end of the shift lever. I have never found it to be that big of bother as is to take a chance of screwing it up with that permanent repair. If you always shift in a slow relaxed manner, it will probably never get stuck in gear. If it gets stuck, it is not that big of deal to unstick.