They listened to the conversation, and realized
that the two visitors were Moses and Elijah.
They were talking to Jesus about His coming
death in Jerusalem. Jesus had a few day earlier
given the disciples a hint of what was going to
happen.

"Verily I say unto you, There be some standing
here, which shall not taste of death, till they see
the Son of man coming in his kingdom"
Matthew 16:28