I have a project which builds fine under gcc 4.8.4. I tried building using gcc 7, and noticed a lot of -Wimplicit-fallthrough= warnings. As far as I'm aware, this was indeed added in gcc version 7. I'm now using -Wno-implicit-fallthrough when building to suppress these warnings. Moving back to the older version of gcc, keeping the -Wno-implicit-fallthrough compiler flag does not lead to any error, even though I do not believe that gcc 4 recognizes this option. How come? Are specifically the -Wno- options allowed to not be recognized?
Using `-Wno-implicit-fallthrough` on older versions of gcc
4.8k Views Asked by jmd_dk At
1
There are 1 best solutions below
Related Questions in LINUX
- Is there some way to use printf to print a horizontal list of decrementing hex digits in NASM assembly on Linux
- Why does Hugo generate different taxonomy-related HTML on different OS's?
- Writes in io_uring do not advance the file offset
- Why `set -o pipefail` gives different output even though the pipe is not failing
- what really controls the permissions: UID or eUID?
- Compiling eBPF program in Docker fails due to missing '__u64' type
- Docker container unable to make HTTPS requests to external API
- Whow to use callback_query_handler in Python 3.10
- Create kea runtime directory at startup in Yocto image
- Problem on CPU scheduling algorithms in OS
- How to copy files into the singularity sandbox?
- Android kernel error: undefined reference to `get_hw_version_platform'
- Is there a need for BPF Linux namespace?
- Error when trying to execute a binary compiled in a Kali Linux machine on an Ubuntu system
- Issue with launching application after updating ElectronJs to version 28.0.0 on Windows and Linux
Related Questions in GCC
- File refuses to compile std::erase() even if using -std=g++23
- the difference between two style of inline ASM
- Why veneer code generated by gcc for cortex-m0 seems 8-byte aligned?
- How to compile the Linux kernel with -O0 for more detailed debug?
- GMP Windows installation "configure: error: could not find a working compiler"
- Unable to run get .exe file from assembly NASM
- Problem with compiling c++ project that is running python code using Python.h -> undefined reference
- How to use a newer linker and glibc in a Kotlin/Native project?
- "Config.guess failed to determine the host type" when trying build binutils-2.7 with Cygwin
- Trying to compile GCC returns a bunch of errors
- Compiling with gcc fno-common option causes performance degradation
- On cygwin I get errors containing -lintl and -liconv when running gcc
- Constant function pointer optimization
- How to obtain mingw-w64 version 9.3.0 or older for MSYS2?
- How to fix this error in terminal while writing hello world code in VS Code on C?
Related Questions in SUPPRESS-WARNINGS
- VSCode Pylance false-positive (?) reaction on ImportError
- Getting IDE0079 ("Remove unnecessary suppression") to play well with NDepend suppressions?
- Which module to specify in Python's filterwarnings()?
- Appropriate use of `void **` for garbage-collected structs in C?
- How to suppress specific Warnings in Java with Gradle in build.gradle file?
- VSCode showing yellow squiggles for null type safety in Spring Boot code
- How to suppress "Line too long" warning (pyright-extended) in Replit Python?
- How to suppress MSBuild warning when external EXE project defined in sln file cannot be found
- Can you enable -Werror=format in Clang, but still allow non-literal format strings? (without using -Wno-format-security)
- Suppressing pyspark warnings before creating session
- How to suppress warning "Be aware, overflowing tokens are not returned"
- xcodebuild swift package: supress all warnings from dependent Swift packages but not the main target
- JAVA MAVEN BUILD fails. Unable to SUPRESS WARNINGS
- Lib.Harmony resharper Name '__instance' does not match rule 'Parameters'. Suggested name is 'instance'
- Suppress warning in Rider for a specific project
Related Questions in GCC-WARNING
- GCC: trying to use -Werror or -pedantic using pragmas
- Neither -Wunused-result, nor --warn-unused-result generates warnings about unused results
- GCC Format attribute not working on function pointer with "using" alias
- Compiler prints HelloWorld whereas Chat GPT says it should only print Hello
- what to do if this error "storage size of `temp_q_trig1' isn't known" occurs in ST programming
- How to resolve C printf %b format warnings
- gcc12 warning use-after-free with shared_ptr of type array
- Is g++ -Wdangling-reference warning justified in this case?
- GCC warns about assigning an initializer list into a vector
- Incompatible pointer type assignment for double pointer to constant double pointer
- GCC warning: how to ignore -Wswitch-default on enum
- can't run simple code in C language in visual studio code
- GCC 5 or newer version
- GCC warning for unintended pointer arithmetic on string literals
- Getting incompatible pointer type warning because the return of the function is not void* but a struct pointer
Related Questions in FALL-THROUGH
- Is it possible in Haskell to write the catch-all pattern first? Or use "negative" pattern?
- Switch object type fallthrough with either identical variable name or null checking?
- Does bash have a `default`-equivalent for the case statement when using fallthrough?
- Don't understand the output of program with a switch block
- Indicating that a switch case falls through
- C-style switch statement with fall-through in Rust
- Proper condition loop
- Typescript possible code paths vs. typing loophole?
- How to check all cases in a switch statement in swift using where keyword?
- Should there be a diagnostic from GCC compiler for this ill-formed C++ code involving [[fallthrough]] attribute?
- R: How to make a switch statement fallthrough
- Using `-Wno-implicit-fallthrough` on older versions of gcc
- Programming Novice - C - Issue with Fall-through in Menu System
- Switch statement fall-through in Java?
- clang not detecting switch fallthroughs
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
Popular # Hahtags
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
From
man gcc:To sum it up: if all goes well, unknown
-Wno-*switches are ignored to preserve compatibility.