• 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: :min, std::max
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: :min, std::max


  • Subject: RE: :min, std::max
  • From: "Carl Smith" <email@hidden>
  • Date: Wed, 26 Oct 2005 10:19:47 -0400
  • Thread-topic: :min, std::max

Thank you all for you help. Yes a couple of you where correct, I was pulling in a header file that was defining max, min. Because we use a lot of common code here in our projects someone at some time had #defined max and min, but because it did not ‘blow up’ in my 1.5 Xcode I was stumped as to the problem.

 

Again thanks for all who took the time to answer my post.

 

Cheers

Carl

 

-----Original Message-----
From: Chris Espinosa
Sent:
Monday, October 24, 2005 6:14 PM
To: Carl Smith
Cc: email@hidden
Subject: Re: :min, std::max

 

 

On Oct 24, 2005, at 2:53 PM, Carl Smith wrote:



As an example of the exact error I am getting;

“error:expected unqualified-id before ‘(‘ token”

then the error is pointing to the line

“const streamsize __limit = std::min(__chunk, __bufavail):” in the file fstream.tcc

there are 12 such errors, all relating to std::min and std::max.

 

The usual cause for this is #defining min or max in some header file.  

 

Often people #define min(x,y) (x < y ? x : y) and that will be expanded in the definition of std:: min, which will blow up.

 

Chris

 _______________________________________________
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

  • Prev by Date: More problems! Building C project (Xcode 1.2 -> 2.1)
  • Next by Date: Re: :min, std::max
  • Previous by thread: Re: :min, std::max
  • Next by thread: SyncServices build issue
  • Index(es):
    • Date
    • Thread