Top "Pragma" questions

The #pragma directives offer a way for each compiler to offer machine- and operating system-specific features while retaining overall compatibility with the C and C++ languages.

GCC #pragma message ignored

I am trying to display a compile-time message in GCC, via #pragma message "hello world" But when I compile with …

c++ c gcc pragma
Any way to group methods in Java/Eclipse?

I would like to be able to group similar methods and have them appear in my Outline view in Eclipse. …

java eclipse pragma
pragma pack(1) nor __attribute__ ((aligned (1))) works

My code used to work in the past, but now the struct size suddenly is 16 bytes. It used to be 13 …

xcode4 llvm pragma pack
How do I show the value of a #define at compile time in gcc

So far I've got as far as: #define ADEFINE "23" #pragma message ("ADEFINE" ADEFINE) Which works, but what if ADEFINE isn't …

c gcc macros c-preprocessor pragma
Safari browser ignoring my no-cache

I'm unable to force a page to always expire in Safari. Chrome, IE and Firefox are good citizens but Safari …

asp.net safari pragma no-cache
Why isn't this library linking with a pragma comment?

I'm using Fmod in a project I'm working on in Visual C++ 2008. If I include ../fmodapi375win/api/lib/fmodvc.…

visual-c++ linker pragma
How do people handle warning C4793: 'some_function' : function compiled as native?

I'm using the OpenCV library and one of its header files, cxoperations.hpp, generates "warning C4793: 'anonymous namespace'::CV_XADD' : …

visual-studio c++-cli opencv warnings pragma
What is the difference between parent and base in Perl 5?

There appears to be a new pragma named parent that does roughly the same thing as base. What does parent …

perl subclass pragma
Suppress -Wunknown-pragmas warning in GCC

I try to ignore warnings coming from some 3rd party header files like this: #pragma GCC diagnostic push #pragma GCC …

gcc warnings pragma suppress-warnings
gcc memory alignment pragma

Does gcc have memory alignment pragma, akin #pragma vector aligned in Intel compiler? I would like to tell compiler to …

optimization memory gcc alignment pragma