I don't remember exactly why I wrote this as a method, but as I don't know anything about racc parser I certainly took inspiration from one of the (not so) many examples I found on the net.
Do you want to remove it and directly replace with yield ?