schnabler
schnabler

Reputation: 715

Xcode Beta 6 - Use of undeclared type 'CLLocationManagerDelegate'

I have just upgraded from Xcode 6 Beta 3 to Xcode 6 Beta 6. In Beta 3, everything worked fine and compiled like I wanted it to.

Right now, I cannot get CLLocationManagerDelegate to work, i.e. I always get the Use of undeclared type 'CLLocationManagerDelegate' - error message.

This is what my file looks like:

import UIKit
import CoreLocation

class ViewController: UIViewController, UITableViewDelegate, UITableViewDataSource, CLLocationManagerDelegate {

Additional info:

Any ideas? I'm assuming something is not linked properly here.

Upvotes: 7

Views: 6799

Answers (3)

Goodsquirrel
Goodsquirrel

Reputation: 1514

Another possible reason for the 'use of undeclared type' error is that your class is also within your test target, but the 'undeclared type' is not.

Upvotes: 4

schnabler
schnabler

Reputation: 715

This was a bug in XCode. Was solved in Beta7/Xcode6.

Upvotes: 2

zisoft
zisoft

Reputation: 23078

Try to clean your build directory:

Product-->Clean

Product-->(Alt key) Clean Build Folder

Delete your derived data:

Window-->Organizer-->delete derived data

Upvotes: 4

Related Questions