473,320 Members | 2,112 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Watcom c++ exceptions in dos4g give undef on good ole ___wcpp_4_fs_handler_

Well try catch compile, link and work ok when l=nt is used, however when l=dos4g is used the jolly old ___wcpp_4_fs_handler_ comes up as an undef with an additional warning of __compiled_under_NT as an undef too, however only the handler is the "final" undef being referenced out of plbx3r.lib(FSHAND).

This problem occurs going all the way back to OW 1.2 strangely it does not occur for watcom 10.6

I have tried to stick in all the ex... headers but to no avail. When linked as nt or dos4g(watcom 10.6) no extra header files are required anyway.

Here is a simple program that will demo the aggravation:
Expand|Select|Wrap|Line Numbers
  1. #include <iostream.h>
  2.  
  3.   int divide(int divisor, int dividend) throw (const char*)
  4.   {
  5.     if (dividend == 0)
  6.       throw (const char*)"Division by zero attempted";
  7.  
  8.     // Here we don't have to worry about dividend being zero
  9.  
  10.     return divisor/dividend;
  11.   }
  12.  
  13.  
  14. int main(void)
  15.   {
  16.     try {
  17.       int result = divide(50,2);
  18.       cout << "divide(" << 50 << ", " << 2
  19.            << ") yields " << result << endl;
  20.       result = divide(50,0);
  21.       cout << "divide(" << 50 << ", " << 0
  22.            << ") yields " << result << endl;
  23.     }
  24.     catch (const char* msg) {
  25.       cout << "Oops, caught: " << msg << endl;
  26.     }
  27.  
  28.     return 0;
  29.   }
  30.  
Anyone any ideas?
Sep 4 '10 #1
0 852

Sign in to post your reply or Sign up for a free account.

Similar topics

10
by: Olivier Parisy | last post by:
Hi all, I am new to Python (I just finished Guido's tutorial). I was very surprised to learn there that the StopIteration is used to end for loops in a standard iterator setting. I come from...
1
by: Az Tech | last post by:
Hi people, (Sorry for the somewhat long post). I request some of the people on this group who have good experience using object-orientation in the field, to please give some good ideas for...
1
by: dover | last post by:
Is std::nothrow only used with new? Under what other situations "std::nothrow" can be used to stop throwing C++ exceptions? (Please give some examples if this is so.) Many thanks!
14
by: Noah Roberts | last post by:
I am a bit confused about how inheritance works with regard to exceptions apparently. class ParentEx : public std::exception { }; class SubEx : public ParentEx,std::runtime_error { };
1
by: Bob Rock | last post by:
Hello, always having to validate an XML stream against a XSD may add up an important overhead. My XMLs are usually the result of serializing a class instance and often in my applications what I...
2
by: headware | last post by:
I realize that when making a web application, performing input validation in the browser is good because it prevents postbacks. However, input checking that goes beyond making sure a value exists...
5
by: Thomas Lotze | last post by:
Hi, I wonder how to solve the following problem the most pythonic way: Suppose you have a function f which, as part of its protocol, raises some standard exception E under certain,...
2
by: ppuniversal | last post by:
Hello, Can someone tell a good Tutorial on Network Programming in C++, except Beej's Guide and Vijay Mukhi's tutorials. I want to make a Client Server application in C++ which will involve...
5
by: Smokey Grindel | last post by:
Is there a list of commonly used exception types out there and what they are intended to be used for? Thanks!
37
by: Sweetiecakes | last post by:
Hello I'm a bit confused on how one should handle exceptions. I'm currently building an ADO.NET Windows Forms application. I've built a class for manipulating data within the database in...
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.