Spoilers for the fifth episode follow, so go back if you don't want to know!
It's widely known at this point that Jon Snow is not the bastard of Ned Stark, but the child of Rhaegar Targaryen and Ned's sister Lyanna. After the R+L=J theory developed over the course of the show, it was all but confirmed in the sixth season finale, "The Winds of Winter."
But Rhaegar was already married to Elia Martell, with whom he had two children. So the given information indicated that Jon was a bastard, albeit a royal bastard, because Rhaegar and Lyanna were not married.
However the latest episode revealed to fans that Rhaegar annulled his marriage to Elia and was likely married to Lyanna in the same secret ceremony in Dorne, meaning Jon Snow is actually the true heir to the Iron Throne.
The reveal came when Gilly was helping Samwell Tarly's preserve the records of the deceased High Septon Maynard, who served in the Great Sept of Baelor. Gilly is remarking how Maynard recorded everything, such as the steps there are in the Citadel, how many windows are in the Great Sept, and even "how many bowel movements he had."
She asks Sam what the word "annulment" means, and he says "it's when a man sets aside his lawful wife."
"Maynard says here that he issued an annulment for a Prince 'Ragger' and remarried him to someone else at the same time in a secret ceremony in Dorne," Gilly explains.
Before she can continue Sam grows annoyed by his current situation and he lashes out, deciding to abandon his training as a maester.
But Game of Thrones fans know that she's referring to Prince Rhaegar Targaryen, and that the Tower of Joy where Lyanna was held with baby Jon Snow is located in Dorne. Meaning Jon Snow is not an actual bastard, he's the true born son of Rhaegar.
Samwell wasn't paying attention, and given what he knows he wouldn't have been able to put that information together about his best friend.
At this point, the producers are basically staring fans in the eye and winking. But the theory of Prince Rhaegar and the three-headed dragon seems to be true, and Jon Snow is actually the true heir to the Iron Throne. Given that he is the surviving son of the Mad King's first born son, his claim is stronger than Daenerys Targaryen's.
We'll see if he gets to sit on it, and if he turns out to be the Prince Who Was Promised, by the end of the series.