• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag
 

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Automatically Remove Unused #import Directives
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Automatically Remove Unused #import Directives


  • Subject: Re: Automatically Remove Unused #import Directives
  • From: Dave Carrigan <email@hidden>
  • Date: Thu, 30 Oct 2008 09:20:42 -0700


On Oct 30, 2008, at 8:37 AM, Jerry Krinock wrote:


On 2008 Oct, 28, at 10:23, George Warner wrote:

On Mon, 27 Oct 2008 22:38:07 -0700, Jerry Krinock <email@hidden> wrote:
After major remodeling of a project, I'm going to have about a hundred
files with an average of maybe 20 #import directives at the top of
each one, and half of them will be no longer necessary since the
symbols that required them were removed or moved to other files during
remodeling.

You could move all the "#import"'s into a precompiler header (.pch) file;
then sort and remove dups.

Thanks, George. I did some reading on .pch files. My conclusion is that, while it would completely eliminate the clutter and make my code ^look^ stunningly beautiful, I'd pay a big penalty in compiler time whenever I added or changed a .h file, which I typically do several times per hour.

You don't ever put your own headers into a pch file; only system headers. It's not clear from your original post whether these #imports were system or project .h files, or a combination.


--
Dave Carrigan
email@hidden
Seattle, WA, USA

Attachment: PGP.sig
Description: This is a digitally signed message part

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Automatically Remove Unused #import Directives
      • From: Dan Korn <email@hidden>
References: 
 >re: Automatically Remove Unused #import Directives (From: George Warner <email@hidden>)
 >Re: Automatically Remove Unused #import Directives (From: Jerry Krinock <email@hidden>)

  • Prev by Date: Re: Automatically Remove Unused #import Directives
  • Next by Date: Re: reference to undefined typeinfo
  • Previous by thread: Re: Automatically Remove Unused #import Directives
  • Next by thread: Re: Automatically Remove Unused #import Directives
  • Index(es):
    • Date
    • Thread