Search code examples
iosxcodeswiftosx-elcapitan

Swift compiler error after upgrading to El-Capitan


I am working on a project developed in Swift. My project was working fine until I upgraded to El-Capitan. As I opened xcode project I am getting this error

Opening import file for module 'Swift': Permission denied

I had refer similar questions on SO but it doesn't solve my problem. I am adding a sreenshot for more clarityenter image description here Please can anyone provide the solution ? Any help would be appriciated. Thank you.


Solution

  • Yes, finally I got the answer. I recreated my project and copy all the code from the previous xcode project. The problem was compiler was not able to find the required file in the project location. I follow these steps.

    1. Quit all projects and xcode completely.
    2. Delete all derived data and dt.xcode from caches folder.
    3. Create new xcode project in some different location.
    4. copy all code from previous xcode.

    hope this will help someone.