Prohibiting the Ideas of the Disbeleivers about Death and Predestination
Allah forbids His believing servants from the disbelievers' false creed, seen in their statement about those who died in battle and during travel; "Had they abandoned these trips, they would not have met their demise." Allah said,
The saying of the hypocrites in verse 156 here is an extension of what was cited in verse 154 earlier: لَوْ كَانَ لَنَا مِنَ الْأَمْرِ شَيْءٌ مَّا قُتِلْنَا هَاهُنَا :"If we had any say in the matter, we would have not been killed here." Since there were chances that sincere Muslims may be affected by such doubt-creating devices used by hypocrites, Muslims were asked through these verses to remain unconcerned with such sayings and doings and adhere to the belief that the span of life and the time of death are ordained by Allah alone.
Tazkirul Quran
Maulana Wahiduddin KhanOn ayahs 158–159
All that happens in this world is by the will of God. However, everything takes place under the veil of cause and effect. Incidents appear to have a cause behind them but, actually, they occur at the will of God. Man’s faith is put to the test through apparent causes, which make it difficult to see the hidden hand of God in all things. The non-believer is the one who is lost in trying to understand the causes and effects, while the believer is one who penetrates their veil to discover the actual reality. One who claims to be a believer, yet regards life and death, success and failure as the results of human strategies, is not true to his claim. When a non-believer suffers a setback, he grieves over it, thinking that had he adopted this or that course, he could have been saved. But when a believer confronts the same situation, he resigns himself to it by accepting it as the will of God. When a man has the conviction that everything happens by God’s will, then all other human causes appear insignificant and not worthy of further consideration. Those, on the other hand, who hold worldly resources important devote their whole lives to providing for the things of this world. But the only things of true value are those which will be theirs in the Hereafter—that is, God’s forgiveness and Paradise. Paradise is something which can be attained only at the cost of one’s life. Man’s existence on earth is the exact price he has to pay to enter Paradise. If he fails to make this sacrifice, he cannot be certain of his fate in the Hereafter.
Uthmani text of the Madinah mushaf (King Fahd Complex). Translation: Saheeh International. Tafsir via Quran.com.