Mail Archives: djgpp/1999/04/01/17:10:37
One way to avoid this problem is using reference.
catch ( sorry& stuff )
btw, How to join the newsgroup of djgpp, where I can find the newsgroup
server for it?
Dennis Yelle wrote:
>
> When I compile this program:
>
> ---------- cut here for bug.cpp -------------------
> #include <iostream.h>
> #include <string.h>
>
> struct sorry{
> const char *error_msg;
> sorry( const char *p) : error_msg(p) {}
> };
>
> int main()
> {
> try {
> throw sorry( "test 3");
> }
> catch ( sorry stuff ) {
> cerr << "Sorry, ";
> cerr << stuff.error_msg ;
> cerr << '\n';
> }
> cout << '\n';
> }
> ---------- cut here for bug.cpp -------------------
>
> with gxx version 2.8.1
> using this:
> gxx -g -Wall bug.cpp -o bug.exe
> I get this:
> bug.cpp: In function `int main()':
> bug.cpp:14: warning: value computed is not used
>
> Can someone tell me which value is not used?
>
> Dennis Yelle
- Raw text -