Since the sample you posted appears to be coded correctly, the error is likely the way the sample relates to the code around it, rather than the contents of the sample.
My first guess is indentation. Is line 924 indented the correct number of tabs (or spaces) under a *choice or *fake_choice line? I’d start by double-checking that.