This question was raised by R. Samuel Eidels in his commentary to this passage. He explains it based on another Talmudic passage (Bava Batra 116a) which explains that King David was described as "lying with his forefathers" while Yoav was described as "dead" because David left behind a worthy son while Yoav did not.
Thus, here Isaiah was telling Hezekiah that he would be considered "dead" in the world to come (like Yoav) because he did not leave behind a son. Hezekiah's response was that even if he did leave behind a son he would still be "dead" because the Talmud there explains that it has to be a worthy son, and Hezekiah had foreseen that his son would be wicked.
ויש לדקדק מאי השיב לו דאכתי תקשי מאי כולי האי וכי משום דלא עסק במצות פ"ו לא תחיה לעוה"ב וי"ל ע"פ מ"ש פרק י"נ דוד נאמר בו שכיבה לפי שהניח בן כמותו יואב שלא הניח בן כמותו נאמר בו מיתה וז"ש לו ולא תחיה לעוה"ב כיון שלא תניח בן כלל שיהיה כמותך וע"ז השיב לו שפיר משום דנפקי מנאי בנין דלא מעלי וגם אם אנסיב אתתא כיון דלא הוה לי בנין כמותי לא אצא מכלל ולא תחיה לעוה"ב דנאמר בו מיתה
R. Ezekiel Landau in his commentary to this passage assumes that it was an exaggeration in order to bring Hezekiah to repentance:
וזה הוכחה שהקב"ה גיזם כדי להחזירו בתשובה לבטל הגזירה
אבל הגיזום לעוה"ב למה