The opening line of One Hundred Years of Solitude in the English translation reads:
Many years later, as he faced the firing squad, Colonel Aureliano Buendía was to remember that distant afternoon when his father took him to discover ice.
I have emboldened the verbs here. I am trying to understand the grammatical structure of the phrase "was to remember".
My understanding, for reference, is that "I ate cake" is the "past tense", "I was eating cake" is the "past progressive", and "I had eaten cake" is a kind of "compound past tense". (I have no knowledge of formal grammar so I'm putting things in quotation marks because I'm not sure the terms are well-defined). What sort of "compound tense" is was to remember?
As a native English speaker, the meaning of the phrase is clear to me. There are three relevant times in this sentence: the time A when Aureliano Buendía discovered ice, the time B when he faced the firing squad, and the time C when I am reading the sentence. A comes before B, and B in turn comes before C.
Because A and B come before C, the sentence is in the past tense. The verb faced is in the simple past because it references an event that took place at time B from the perspective of the current time C. Similarly, "took him to discover" is in the simple past because it refers to an event that took place at time A from the perspective of the current time C. The "was to remember" is different: it refers to an event taking place at time A from the perspective of the later time B, both times being before the present time C. So it seems like a "past within a past" construction.
I've been trying to think of examples of using "was to [infinitive]", but all the examples I can think of involve an additional participle in between the was and the infinitive:
I was supposed to buy groceries, but I forgot.
He was trying to call me.