Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork34.1k
Comments
gh-116869: Fix redefinition of the _PyOptimizerObject type#116963
Merged
vstinner merged 1 commit intopython:mainfromMar 18, 2024
Merged
gh-116869: Fix redefinition of the _PyOptimizerObject type#116963vstinner merged 1 commit intopython:mainfrom
vstinner merged 1 commit intopython:mainfrom
Conversation
Defining a type twice is a C11 feature and so makes the C APIincompatible with C99. Fix the issue by only defining the type once.Example of warning (treated as an error): In file included from Include/Python.h:122: Include/cpython/optimizer.h:77:3: error: redefinition of typedef '_PyOptimizerObject' is a C11 feature [-Werror,-Wtypedef-redefinition] } _PyOptimizerObject; ^ build/Include/cpython/optimizer.h:60:35: note: previous definition is here typedef struct _PyOptimizerObject _PyOptimizerObject; ^
vstinner added a commit to vstinner/cpython that referenced this pull requestMar 20, 2024
…hon#116963)Defining a type twice is a C11 feature and so makes the C APIincompatible with C99. Fix the issue by only defining the type once.Example of warning (treated as an error): In file included from Include/Python.h:122: Include/cpython/optimizer.h:77:3: error: redefinition of typedef '_PyOptimizerObject' is a C11 feature [-Werror,-Wtypedef-redefinition] } _PyOptimizerObject; ^ build/Include/cpython/optimizer.h:60:35: note: previous definition is here typedef struct _PyOptimizerObject _PyOptimizerObject; ^
adorilson pushed a commit to adorilson/cpython that referenced this pull requestMar 25, 2024
…hon#116963)Defining a type twice is a C11 feature and so makes the C APIincompatible with C99. Fix the issue by only defining the type once.Example of warning (treated as an error): In file included from Include/Python.h:122: Include/cpython/optimizer.h:77:3: error: redefinition of typedef '_PyOptimizerObject' is a C11 feature [-Werror,-Wtypedef-redefinition] } _PyOptimizerObject; ^ build/Include/cpython/optimizer.h:60:35: note: previous definition is here typedef struct _PyOptimizerObject _PyOptimizerObject; ^
diegorusso pushed a commit to diegorusso/cpython that referenced this pull requestApr 17, 2024
…hon#116963)Defining a type twice is a C11 feature and so makes the C APIincompatible with C99. Fix the issue by only defining the type once.Example of warning (treated as an error): In file included from Include/Python.h:122: Include/cpython/optimizer.h:77:3: error: redefinition of typedef '_PyOptimizerObject' is a C11 feature [-Werror,-Wtypedef-redefinition] } _PyOptimizerObject; ^ build/Include/cpython/optimizer.h:60:35: note: previous definition is here typedef struct _PyOptimizerObject _PyOptimizerObject; ^
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading.Please reload this page.
Defining a type twice is a C11 feature and so makes the C API incompatible with C99. Fix the issue by only defining the type once.
Example of warning (treated as an error):