2011-07-19 43 views
0

我的iPhone應用程序中有一個名爲ReportsViewController的類。我想從舊版本的複製到文本文件的類中恢復它。我複製並粘貼了所有東西,現在一切都出錯了。我收到以下錯誤:iPhone應用程序 - 複製並粘貼一個類,現在全部出錯

ld: duplicate symbol _OBJC_METACLASS_$_ReportsViewControllers in /Users/myname/Library/Developer/Xcode/DerivedData/TestGA-gipaszaocsrbkwashqjghthtsoda/Build/Intermediates/TestGA.build/Release-iphoneos/TestGA.build/Objects-normal/armv6/ReportsViewControllers.o and /Users/myname/Library/Developer/Xcode/DerivedData/TestGA-gipaszaocsrbkwashqjghthtsoda/Build/Intermediates/TestGA.build/Release-iphoneos/TestGA.build/Objects-normal/armv6/MasterGA.o for architecture armv6 
collect2: ld returned 1 exit status 
Command /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/gcc-4.2 failed with exit code 1 

我該如何解決這個問題?

+3

我會全力以赴胡迪尼在你的堆棧跟蹤和猜測你有一個重複的符號的地方在你的代碼中。 – Perception

回答

2

被錯誤判斷,您已經有了一個ReportsViewControllers兩個聲明。你需要找到你不想要的並刪除它。

+0

你是什麼意思兩個聲明? – CodeGuy

+2

這是它的兩個版本。搜索它。 – 2011-07-19 15:53:26

0

要麼有兩個類文件,或「DUBBLE粘貼」這意味着有2 myController的@implementaion