Compiler Warning with -Wunreachable-code


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers Compiler Warning with -Wunreachable-code
# 1  
Old 06-30-2010
Compiler Warning with -Wunreachable-code

Hi,

On compiling my code with flag -Wunreachable-code, I'm getting compiler warnings
../source/XmlFile.cpp:203: warning: will never be executed

Line 203 reads
throw XmlException("XmlFile::BLAH!!!");

This exception is thrown explicitly and obviously works !!

I'm using
$ gcc --version
gcc (GCC) 4.2.1

on debian Linux
$ uname -a
Linux H00001 2.6.26-1-686 #1 SMP Sat Jan 10 18:29:31 UTC 2009 i686 GNU/Linux

Compiler bug or am I just imagining things?

Regards
Ishdeep
 
Login or Register to Ask a Question

Previous Thread | Next Thread

3 More Discussions You Might Find Interesting

1. Programming

Incompatiblity of the code due to CC compiler version mismatch.

Incompatiblity of the code due to CC compiler version mismatch. I have a machine with Machine A-- Operating System:SunOs 5.8 Generic_117350-45 sun4u sparc SUNW,Ultra-80(solaris 5.8) CC Compiler:CC: WorkShop Compilers 4.2 16 Jun 1998 C++ 4.2 patch 104631-07 we have compiled C++... (36 Replies)
Discussion started by: Revathi R
36 Replies

2. Programming

How Can a Machine Reads a Compiler Since A Compiler is Written in Text! Not Binaries?

To make a programming language you need a compiler, so what was the first programming language and how was is created if you need the compiler first? The compiler itself is considered as a high language comparing to the machine! since the compiler is not created in 1's and 0's... Eventhough i... (12 Replies)
Discussion started by: f.ben.isaac
12 Replies

3. Programming

gcc compiler warning

The gcc compiler is giving following error in my code. Can Anyone help, why is this warning popping up. "void format, different type arg (arg 1)" The function's on which warning is given, looks like this: void fprint_stderr_sockarray(int* sockets) { .......... .......... } (2 Replies)
Discussion started by: Ahsan
2 Replies
Login or Register to Ask a Question
SFC(1)							      General Commands Manual							    SFC(1)

NAME
sfc - The SyFi Form Compiler SYNOPSIS
sfc [OPTIONS] input.form ... DESCRIPTION
The SyFi Form Compiler (SFC) is a form compiler from the FEniCS project, compiling variational forms from the Unified Form Language (UFL) to efficient C++ implementations of Unified Form-assembly Code (UFC). SFC uses symbolic expressions for finite elements from SyFi. OPTIONS
-h, --help Display help text and exit. -o DIRECTORY, --outputdir DIRECTORY Output directory. -p PREFIX, --prefix PREFIX Prefix string. -O LEVEL Compiler optimization level. -c CACHE, --cache CACHE Use JIT compiler cache. -i METHOD, --integration-method METHOD Specify integration method. METHOD may be either quadrature (default) or symbolic. -d ORDER, --integration-order ORDER Specify integration order. -w, --dolfin-wrappers Generate DOLFIN C++ wrapper code. -b, --benchmark Run benchmark of element tensor computation. -s, --safemode Use safe mode when generating (quadrature) code, writing complete integrand expressions unmodified. -g DEBUGLEVEL, --debug DEBUGLEVEL Enable generation of debugging code. -t, --timing Enable timing of code generation process. BUGS
Send comments, questions, bug reports etc. to syfi-dev@fenics.org. LICENSE
SFC is licensed under the GNU LGPL Version 2, the same AUTHOR
SFC is written by Martin Sandve Alnaes <martinal@simula.no> and Kent-Andre Mardal <kent-and@simula.no>. This manual page is written by Johannes Ring <johannr@simula.no>. SFC(1)