"And you would think them awake" meaning: their eyes are open, "while they are asleep."
Muhammad said: The awake are those who are alert, and the sleeping are those who are asleep. "And We turn them to the right and to the left." Qatada said: In their first sleep before they died.
Abu Iyad said: They are turned twice every year. "And their dog stretching his forelegs at the entrance," meaning: at the courtyard of the cave. "If you had looked at them, you would have turned from them in flight and would have been filled with terror of them."
Muhammad said: "In flight" (firaran) is in the accusative case as a verbal noun (masdar), because the meaning of 'you would have turned' (walayta) is 'you would have fled' (fararta), and "terror" (ru'ban) is in the accusative case as a specification (tamyiz).
﴿وتحسبهم أيقاظا﴾ أَيْ: مُفَتَّحَةٌ أَعْيُنُهُمْ ﴿وَهُمْ رُقُودٌ﴾.
قَالَ مُحَمَّدٌ: الْأَيْقَاظُ: الْمُنْتَبِهُونَ، وَالرُّقُودُ: النِّيَامُ. ﴿وَنُقَلِّبُهُمْ ذَاتَ الْيَمِينِ وَذَاتَ الشمَال﴾ قَالَ قَتَادَةُ: فِي رَقْدَتِهِمُ الْأُوْلَى قَبْلَ أَنْ يَمُوتُوا.
قَالَ أَبُو عِيَاضٍ: لَهُمْ فِي كُلِّ عَامٍ تَقْلِيبَتَانِ ﴿وَكَلْبُهُمْ بَاسِطٌ ذِرَاعَيْهِ بِالْوَصِيدِ﴾ أَيْ: بِفِنَاءِ الْكَهْفِ ﴿لَوِ اطَّلَعْتَ عَلَيْهِمْ لَوَلَّيْتَ مِنْهُمْ فِرَارًا وَلَمُلِئْتَ مِنْهُم رعْبًا﴾.
قَالَ مُحَمَّد: (فِرَارًا) مَنْصُوبٌ عَلَى الْمَصْدَرِ؛ لِأَنَّ مَعْنَى وليت: فَرَرْت، و (رعْبًا) مَنْصُوب على التَّمْيِيز.