Suddenly it stops building application in device. In simulator its working but when I connect the device and try to run it in device it gives me an error:
If cleaning the project and deleting the 'derived data' doesn't work, try to change the 'Deployment target' (at 'General' tab) from 7.0 to 7.1
If your project builds for another target (e.g. it builds for simulator and NOT your device), then it's confirmed you accidentally edited one of the header files of the frameworks for that target. The affected framework is the one you are receiving compiling errors for.
Cleaning some unnecessary Xcode data using DevCleaner for Xcode app worked for me.
If you have two Xcode then uninstall both and again install Xcode. It worked for me.
My error was a wrong version of command line tools - go to Preferences->Locations and change the command line tools version - quit xcode and try again.
For some reason your UIKit.framework is corrupted, either copy a working UIKit.framework from somewhere else into
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks
Or reinstall Xcode the fix the issue.