Skip to content

Fix MSVC build: rename constant identifier to avoid Windows SDK macro conflict - #3

Closed
JoseAntFer with Copilot wants to merge 2 commits into
mainfrom
copilot/fix-windows-2022-job-failure
Closed

Fix MSVC build: rename constant identifier to avoid Windows SDK macro conflict#3
JoseAntFer with Copilot wants to merge 2 commits into
mainfrom
copilot/fix-windows-2022-job-failure

Conversation

Copilot AI commented Aug 4, 2026

Copy link
Copy Markdown

The windows-2022 CI job was failing because constant is defined as a macro in MSVC's Windows SDK/OpenCL headers, conflicting with its use as a parameter name and struct field in the codebase.

Changes

  • Expressions.h / Expressions.cpp: Rename parameter double constantdouble val in declare_constant_float()
  • FixedBranchSequence.h: Rename Op struct field double constantdouble const_val and matching constructor parameter
  • Compilation.cpp, FixedBranchSequence.cpp: Update op.constantop.const_val at all call sites

MSVC error before fix:

symx/src/symbol/utils.h(10,65): error C2143: syntax error: missing ')' before 'constant'
symx/src/symbol/utils.h(10,65): error C2059: syntax error: 'constant'

…lict

Co-authored-by: JoseAntFer <16940999+JoseAntFer@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix failing GitHub Actions job windows-2022 Fix MSVC build: rename constant identifier to avoid Windows SDK macro conflict Aug 4, 2026
Copilot AI requested a review from JoseAntFer August 4, 2026 16:36
@JoseAntFer JoseAntFer closed this Aug 4, 2026
@JoseAntFer
JoseAntFer deleted the copilot/fix-windows-2022-job-failure branch August 4, 2026 17:13
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.

2 participants