Prev: 772F Up: Map Next: 7790
7733: Inglish: Restore The Match
Restores a saved match and tries the clause again. Reached through the jump table at JumpTable, dispatched from 75D0.
InglishRestoreTheMatch 7733 BIT 3,E Jump to InglishRestoreTheMatch_TestTheGrammarFlag if bit 3 of the grammar flag is set.
7735 JR NZ,InglishRestoreTheMatch_TestTheGrammarFlag
7737 CALL Inglish_TestTheConjunctionCount Call Inglish_TestTheConjunctionCount to test the conjunction count.
773A JR NZ,InglishRestoreTheMatch_TestTheGrammarFlag Jump to InglishRestoreTheMatch_TestTheGrammarFlag if a conjunction is still left.
773C LD HL,($7574) Read the pointer stored at InglishPrepareTheClause.
773F LD ($B6DC),HL Update *B6DC.
7742 LD D,$B0 The restored class is B0.
7744 LD A,($7576) Read the saved grammar flag.
7747 LD E,A Keep the saved grammar flag.
7748 LD A,($7579) Read the saved replay path.
774B LD ($B706),A Update *B706.
774E LD IY,($7577) Read the saved matcher pointer.
7752 JP InglishMatchOneWord Jump to InglishMatchOneWord to match one word.
InglishRestoreTheMatch_TestTheGrammarFlag 7755 CALL Inglish_ClearTheMatcherPhase_0 Call Inglish_ClearTheMatcherPhase_0 to clear the matcher phase.
7758 BIT 1,E Jump to Inglish_AskWhat_0 if bit 1 of the saved grammar flag is clear.
775A JP Z,Inglish_AskWhat_0
775D BIT 0,E Jump to InglishRestoreTheMatch_SaveTheTokenPointer if the match bit of the saved grammar flag is clear.
775F JR Z,InglishRestoreTheMatch_SaveTheTokenPointer
InglishRestoreTheMatch_StoreThePairOfClauseBytes 7761 CALL Inglish_StoreTheBytePair Call Inglish_StoreTheBytePair to store the pair of clause bytes.
7764 JP InglishPrepareTheClause_3 Jump back to InglishPrepareTheClause_3 to clear the matcher scratch.
InglishRestoreTheMatch_SaveTheTokenPointer 7767 PUSH DE Save DE, BC and the token pointer at B6DC on the stack.
7768 PUSH BC
7769 LD HL,($B6DC)
776C PUSH HL
InglishRestoreTheMatch_Loop 776D CALL Inglish_ReadTheNextGrammarByte Call Inglish_ReadTheNextGrammarByte to read the next grammar byte.
7770 CP $00 Jump back to InglishRestoreTheMatch_Loop if the grammar byte is zero.
7772 JR Z,InglishRestoreTheMatch_Loop
7774 SET 0,E Set bit 0 of E, and jump to InglishRestoreTheMatch_StoreTheNextPair if the grammar byte is 20.
7776 CP $20
7778 JR Z,InglishRestoreTheMatch_StoreTheNextPair
777A POP HL Update *B6DC.
777B LD ($B6DC),HL
777E POP BC Jump back to InglishRestoreTheMatch_StoreThePairOfClauseBytes to store the next pair of clause bytes.
777F POP DE
7780 JR InglishRestoreTheMatch_StoreThePairOfClauseBytes
InglishRestoreTheMatch_StoreTheNextPair 7782 CALL Inglish_StoreTheBytePair Call Inglish_StoreTheBytePair to store the pair of clause bytes.
7785 POP HL Drop one saved value, restore BC and HL, and force L to 02.
7786 POP BC
7787 POP HL
7788 LD L,$02
778A CALL Inglish_StoreTheBytePair_0 Call Inglish_StoreTheBytePair_0 to store the pair of clause bytes.
778D JP InglishPrepareTheClause_3 Jump back to InglishPrepareTheClause_3 to clear the matcher scratch.
Prev: 772F Up: Map Next: 7790