AMReX-Astro / AMReX-Astro/Microphysics

RKC: actual_integrator.H and actual_integrator_sdc.H share the same include guard

Open Beginner friendly
#1,954 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

ai-code-audit integrator
Dominant language
C++
Stars
43
Forks
46
Avg merge
2d 18h
Merged PRs (30d)
15

Description

Summary

Both files use:

#ifndef actual_integrator_H
#define actual_integrator_H
Why this is a bug

If a translation unit includes both headers (directly or transitively), the second include is skipped entirely because the guard macro is already defined. This can silently hide required declarations/definitions and create build or behavior differences depending on include order.

Location
  • integration/RKC/actual_integrator.H
  • integration/RKC/actual_integrator_sdc.H
Suggested fix

Use unique include guards per file (or #pragma once), e.g. actual_integrator_strang_H and actual_integrator_sdc_H.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Inspect the include guards in integration/RKC/actual_integrator.H and integration/RKC/actual_integrator_sdc.H, then confirm that each header uses a distinct guard. Verify that a translation unit can include both headers without either being skipped, and run the relevant project build or tests to check for regressions.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
backend
Issue type
Bug
Difficulty
1/5
Estimated time
Under an hour
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
68/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.