llnl / llnl/sundials

Avoid use of reserved names.

Open
#114 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

api-change enhancement feature-request
Dominant language
C
Stars
686
Forks
167
Avg merge
1d 20h
Merged PRs (30d)
17

Description

The page at https://github.com/LLNL/sundials/blob/develop/doc/shared/sundials/SUNContext.rst describes the Context structure as declared as follows:

struct _SUNContext *SUNContext

This is unfortunate: Both C and C++ reserve all names that (i) start with an underscore, followed by an uppercase letter, (ii) start with two underscores. See https://en.cppreference.com/w/cpp/language/identifiers .

I haven't checked whether that's the only name in SUNDIALS that has this problem, or whether that's a pattern. Either way, it's probably worth avoiding the issue, and because these names aren't part of the public interface, it shouldn't even be that difficult to rename things if you so chose.

Contributor guide

Open the contributing guide

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

The reported location is doc/shared/sundials/SUNContext.rst; start there, then search the repository for similarly reserved internal names in C and C++ declarations. Done means the affected internal names no longer use the reserved patterns and the documentation reflects the resulting names.

Written by the indexing model from the issue text.

Assessment

Tech stack
c, cpp
Domain
compilers, hpc
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.