Skip to content

Include StaticRecompCore.h where the interpreter uses it - #7

Open
dougchansan wants to merge 1 commit into
ExpansionPak:moderngekko-vendorfrom
dougchansan:interpreter-staticrecomp-include
Open

Include StaticRecompCore.h where the interpreter uses it#7
dougchansan wants to merge 1 commit into
ExpansionPak:moderngekko-vendorfrom
dougchansan:interpreter-staticrecomp-include

Conversation

@dougchansan

Copy link
Copy Markdown

core does not compile at the moderngekko-vendor tip (7275711) with MSVC:

Interpreter.cpp(294): error C2065: 'g_static_recomp_core': undeclared identifier
Interpreter.cpp(299): error C2065: 'ppc_state': undeclared identifier

unknown_instruction reads both, but the translation unit includes neither the header declaring g_static_recomp_core (Core/PowerPC/StaticRecomp/StaticRecompCore.h) nor a binding for ppc_state. It is not reached through the precompiled header either — pch.h does not pull in StaticRecompCore.h.

The ppc_state binding already existed further down the same function, past the first use. This moves it to the top so it serves both uses; adding a second one is a redefinition (C2374).

Found while building moderngekko-launcher from ModernGekko master. It is the second of two breaks in that path — the first is the unguarded PCH flags, already fixed on this branch, which is why this one was not visible until now.

Two lines, no behaviour change.

unknown_instruction reads g_static_recomp_core and ppc_state, but the
translation unit includes neither the header that declares the former nor
a binding for the latter, so core does not compile:

  Interpreter.cpp(294): error C2065: 'g_static_recomp_core': undeclared identifier
  Interpreter.cpp(299): error C2065: 'ppc_state': undeclared identifier

It is not reached through the PCH either -- pch.h does not pull in
StaticRecompCore.h.

The ppc_state binding already existed further down the same function, past
the first use. Moving it to the top serves both uses rather than adding a
second one, which would be a redefinition.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant