• 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: Header Files
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Header Files


  • Subject: Re: Header Files
  • From: Conrad Shultz <email@hidden>
  • Date: Tue, 30 Aug 2011 18:49:41 -0700

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 8/30/11 6:07 PM, koko wrote:
> Say I have two header files with the same name.  (Long story as to
> why so let's get past that for now).
>
> I put them in folders:
>
> Folder A Folder B
>
> So I have
>
> Folder A Header.h Folder B Header.h
>
> How do I construct my #include to get the header I want included as
> in:
>
> implem1.cpp #include Folder A/Header.h
>
> implem2.cpp #include Folder B/Header.h

You can simply make the common parent directory part of your header
search path then include the files just as you did (with appropriate
quotation marks).

(I just wrote a trivial little C++ program and compiled with g++ on
the command line to verify.)

- --
Conrad Shultz

Synthetiq Solutions
www.synthetiqsolutions.com

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iD8DBQFOXZM1aOlrz5+0JdURAhfEAJ9ZP/GTMcHmXZsY51uVx/s5nTN0nwCbBXZJ
ufcR7zmJwHmsnxb+8rep/1A=
=Vyhi
-----END PGP SIGNATURE-----
 _______________________________________________
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: Header Files
      • From: koko <email@hidden>
References: 
 >Headrer Files (From: koko <email@hidden>)

  • Prev by Date: Headrer Files
  • Next by Date: Re: Header Files
  • Previous by thread: Headrer Files
  • Next by thread: Re: Header Files
  • Index(es):
    • Date
    • Thread