• 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: Carbon with UNIX
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Carbon with UNIX


  • Subject: Re: Carbon with UNIX
  • From: Robert Tillyard <email@hidden>
  • Date: Mon, 17 Jan 2005 10:51:10 +0000

You need:-

int main ()
{
struct aaa a;

}

Regards, Rob.

On 17 Jan 2005, at 10:02 am, Alexey Proskuryakov wrote:

On 17.01.2005 00:31, "Ian Krieg" <email@hidden> wrote:

Apparently this is not exactly the reason. I made a test file and had the
same problem you did. When I defined a struct of my own in the file, it could
be used fine without the struct keyword. I thought perhaps it was something
about how the API headers were treated after being included, so I found an
arbitrary struct in another header, "_pthread_handler_rec", but it worked fine
without the keyword "struct".

Here is a simpler test case (remember that stat is both a struct and a
function):


----------
struct aaa {};

int aaa();

int main ()
{
    aaa a;
}
----------

Both gcc and Comeau dislike it. I don't know which paragraph of the
standard should be cited as a reason; but it definitely seems to be standard
behavior.


- WBR, Alexey Proskuryakov

_______________________________________________ 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: Carbon with UNIX
      • From: Alexey Proskuryakov <email@hidden>
References: 
 >Re: Carbon with UNIX (From: Alexey Proskuryakov <email@hidden>)

  • Prev by Date: Re: Carbon with UNIX
  • Next by Date: Re: Carbon with UNIX
  • Previous by thread: Re: Carbon with UNIX
  • Next by thread: Re: Carbon with UNIX
  • Index(es):
    • Date
    • Thread