Article View: comp.sys.mac.programmer.codewarrior
Article #932Re: MACOSX CODEWARRIOR8 and cosf, sinf, tanf, sqrtf, etc
From: Derek Ledbetter
Date: Thu, 10 Oct 2002 01:00
Date: Thu, 10 Oct 2002 01:00
29 lines
2025 bytes
2025 bytes
On Wed, 9 Oct 2002 17:11:20 -0700, News Reader wrote
(in message <s7h9qusl2tjo42e3egbblef5c8flaqjo28@4ax.com>):
> What must I do to be able to use cosf, sinf, tanf, etc in Codewarrior8
> on MacOSX for a MacOSX target? Am I missing a define somewhere?
>
> I tried this:
>
> test.cpp:
> #include <cmath>
> void test()
> {
> cosf(0.32342f);
> }
>
>
> In the project settings, I have the standard /usr/include path, the
> MSL dir, and the MacOSX support dir.
>
> It says it can't find cosf, but doing a search in MSL's cmath header
> file, I see it there...
Since you included <cmath> instead of <math.h>, cosf is in the std
namespace.
--
Derek Ledbetter
derekledbetter@mindspring.com
"Life's short and hard like a body-building elf."
Technical Details
Message-ID:
<0001HW.B9CA1F2D02E8A14AF0284600@news.mindspring.com>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!cyclone.bc.net!newsfeed.media.kyoto-u.ac.jp!newsfeed.news2me.com!border1.nntp.aus1.giganews.com!nntp2.aus1.giganews.com!nntp.giganews.com!newsfeed1.earthlink.net!newsfeed.earthlink.net!stamper.news.pas.earthlink.net!stamper.news.atl.earthlink.net!harp.news.atl.earthlink.net!not-for-mailReferences:
<s7h9qusl2tjo42e3egbblef5c8flaqjo28@4ax.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 10bcce,42d92dc96528dba3 X-Google-Attributes: gid10bcce,public X-Google-Thread: f635e,42d92dc96528dba3 X-Google-Attributes: gidf635e,public X-Google-ArrivalTime: 2002-10-09 18:00:01 PST Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!cyclone.bc.net!newsfeed.media.kyoto-u.ac.jp!newsfeed.news2me.com!border1.nntp.aus1.giganews.com!nntp2.aus1.giganews.com!nntp.giganews.com!newsfeed1.earthlink.net!newsfeed.earthlink.net!stamper.news.pas.earthlink.net!stamper.news.atl.earthlink.net!harp.news.atl.earthlink.net!not-for-mail From: Derek Ledbetter <derekledbetter@mindspring.com> Newsgroups: comp.sys.mac.programmer.codewarrior,codewarrior.mac Subject: Re: MACOSX CODEWARRIOR8 and cosf, sinf, tanf, sqrtf, etc Date: Wed, 9 Oct 2002 18:00:13 -0700 Organization: MindSpring Enterprises Lines: 31 Message-ID: <0001HW.B9CA1F2D02E8A14AF0284600@news.mindspring.com> References: <s7h9qusl2tjo42e3egbblef5c8flaqjo28@4ax.com> Reply-To: derekledbetter@mindspring.com NNTP-Posting-Host: a5.f7.cc.c6 Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Server-Date: 10 Oct 2002 01:00:00 GMT User-Agent: Hogwasher/3.1 (Carbon/OSX)