GCC compiler error: “redefinition…previously defined”

前端 未结 4 1814
再見小時候
再見小時候 2021-02-02 15:39

I\'m getting a lot of \" redefinition of x....x previously defined here\". Please what does this error means?

4条回答
  •  盖世英雄少女心
    2021-02-02 16:24

    You are probably including a header file twice. Make sure your header files are surrounded by #ifndef statements.

    http://www.fredosaurus.com/notes-cpp/preprocessor/ifdef.html

提交回复
热议问题