Marin
Marin

Reputation: 12910

Xcode 6 Refactor : Can only refactor C and Objective C code

I'm getting the above error trying to rename an array. Is there any other way? Trying this

Right click on variable -> Refactor -> Rename 

I'm sure there has to be another way?

Upvotes: 13

Views: 3598

Answers (1)

Ray Perea
Ray Perea

Reputation: 5851

If you want to rename a local variable within a method or function and just want to rename all occurrences within that function, try this...

Click on the variable and leave your mouse there for a moment.... A down arrow will appear just to the right of the variable name. Click on that down arrow and choose "Edit All In Scope"

Once you click on the variable, notice the small down arrow to the right of it

Click on Edit All in Scope

Upvotes: 15

Related Questions