Solved

math.h error..

Posted on 2001-09-14
3
582 Views
Last Modified: 2007-11-27
I'm using math.h in my C++ application trying to compile that using Sun WorkShop 6 update 1 C++ 5.2 2000/09/11 compiler but hitting the following error
"/usr/include/math.h", line 189: Error: The name exception is ambiguous, exception and std::exception." there is a structure by name exception in math.h probably bcoz of that.. not able to proceed further does anyone have any idea or got an error like this?? please help... well if I use this option during compilation -library=Cstd then I can get rid of this error, but then I want to use Cstd library for lot of other standard template classes.

Lalitha
0
Comment
Question by:alalitha
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 30

Accepted Solution

by:
Axter earned 100 total points
ID: 6482389
Have you tried using the extensionless version?

#include <cmath>
0
 
LVL 30

Expert Comment

by:Axter
ID: 6482397
You're probably getting this because you're mixing extensionless headers with extension headers and using the "using namespace std".

Try either using all extensionless headers, or try not declaring "using namespace std".
0
 

Author Comment

by:alalitha
ID: 6482503
thanks changed to #include <cmath> and it worked but its giving warnings like this not able to figure out these

__1cDstdElist4nFRecSt_n0AJallocator4n0B____Ferase6Mn0DIiterator_2_2_ is out-of-date and will be regenerated
__1cDstdElist4nFRecSt_n0AJallocator4n0B____U__deallocate_buffers6M_v_ is out-of-date and will be regenerated
__1cDstdElist4nFRecSt_n0AJallocator4n0B____M__insert_aux6Mn0DIiterator_Irkn0B__v_ is out-of-date and will be re
generated

Lalitha
0

Featured Post

[Webinar] Code, Load, and Grow

Managing multiple websites, servers, applications, and security on a daily basis? Join us for a webinar on May 25th to learn how to simplify administration and management of virtual hosts for IT admins, create a secure environment, and deploy code more effectively and frequently.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Unable to start eclipse ? 17 174
show out valin of json for debugging in visaul c++ 1 54
Indy 10 not Receiving UDP broadcast 3 56
Winapi.Windows.hpp problem 7 45
When writing generic code, using template meta-programming techniques, it is sometimes useful to know if a type is convertible to another type. A good example of when this might be is if you are writing diagnostic instrumentation for code to generat…
Container Orchestration platforms empower organizations to scale their apps at an exceptional rate. This is the reason numerous innovation-driven companies are moving apps to an appropriated datacenter wide platform that empowers them to scale at a …
The viewer will learn how to clear a vector as well as how to detect empty vectors in C++.
The viewer will be introduced to the technique of using vectors in C++. The video will cover how to define a vector, store values in the vector and retrieve data from the values stored in the vector.

738 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question