Solved: no template named ‘stack’ on Xcode 14.3

When I updated the Xcode from 14.2 to 14.3, a project report the following error:

Solved: no template named ‘stack’ on Xcode 14.3

When I updated the Xcode from 14.2 to 14.3, a project report the following error:

no template named 'stack'

Solution

To resolve the problem, add the following include statement.

#include <stack>