• 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: usage of #import?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: usage of #import?


  • Subject: Re: usage of #import?
  • From: "Philippe C.D. Robert" <email@hidden>
  • Date: Sun, 10 Nov 2002 11:30:41 +0100

Hi Wilfredo,

I do not exactly know the official reasoning from the FSF against the usage of this feature, but as Stan points out in his email there are indeed some valid reasons for not using it in ObjC code (in some circumstances):

http://mail.gnu.org/pipermail/discuss-gnustep/2001-October/013735.html

So my original question was more whether Apple will go and try to 'de-deprecate' it since they seem to have made their minds wrt using this feature and since they seem to work together with the FSF or not.

But then, all this is not that important, I was just curious...:-)

-Phil

PS: And yes, Don, I am also around since NeXT days and I know about the long history this feature has. Call me pedantic, but just saying 'Stallman is wrong, end of story' does not solve the issue because strictly speaking Apple uses the FSF compiler and thus stays in conflict with the official guidelines. As even mentioned in the man pages coming with Mac OS X (-W{no-}import)..:-)

On Sunday, November 10, 2002, at 08:33 Uhr, Wilfredo Sanchez wrote:

It's not good form to use it on ASNI C headers, as it's not the documented way to use them, and the behavior is different, so if things break, it's entirely your fault. Most likely, things won't break, but it's still not the correct thing to do, and it doesn't buy you anything.

There's nothing wrong with #import for ObjC, as it never makes sense to read a class interface twice. As Don pointed out, the objection from the FSF in that context isn't well justified.

-wsv


On Saturday, November 2, 2002, at 11:13 AM, Philippe C.D. Robert wrote:

the official advice/message/rule from the gcc folks is not to use "#import" anymore at all. Although it still works with gcc 3.x it is considered as deprecated (see -Wno-import).
Now Apple is still using #import in 10.2 thus I wonder what Apple's position is in this respect? What should be used by 3rd party developers for custom ObjC code? How will Apple deal with this in the future?


--
Philippe C.D. Robert
http://www.nice.ch/~phip
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

  • Follow-Ups:
    • Re: usage of #import?
      • From: Don Yacktman <email@hidden>
  • Prev by Date: Re: "weak link" framework refs for 10.1 compatibility?
  • Next by Date: Re: TableColumn dataCell actions
  • Previous by thread: Re: usage of #import?
  • Next by thread: Re: usage of #import?
  • Index(es):
    • Date
    • Thread