Skip to content

[newchem-cpp] cppify interp_table_utils.{h->hpp} #461

Merged
brittonsmith merged 5 commits into
grackle-project:newchem-cppfrom
mabruzzo:ncc/cppify-interp_table_utils
Jan 20, 2026
Merged

[newchem-cpp] cppify interp_table_utils.{h->hpp} #461
brittonsmith merged 5 commits into
grackle-project:newchem-cppfrom
mabruzzo:ncc/cppify-interp_table_utils

Conversation

@mabruzzo

@mabruzzo mabruzzo commented Dec 8, 2025

Copy link
Copy Markdown
Collaborator

To be reviewed after #428 is merged

This is a really tiny PR. I'm introducing it because it will be very helpful in finishing #447. It did 3 minor things:

  1. converted interp_table_utils.h -> interp_table_utils.hpp
  2. I added the ability to use delete[] for cleaning up a gr_interp_grid_props instance in anticipation of a change in [newchem-cpp] introduce GrainMetalInjectPathways type #447 (the change probably could have waited until then, but it was small enough to do it now).1
  3. I relocated the function for initializing empty gr_interp_grid_props and gr_interp_grid out of initialize_chemistry.cpp into interp_table_utils.hpp

Footnotes

  1. I'm hesitant to go through and convert change every malloc/free to new[]/delete[] involving a gr_interp_grid_props or a gr_interp_grid in this PR because I can't remember if I introduced any more instances in pending PRs. Honestly, I don't think I did, but if I'm wrong, debugging a mismatched malloc/delete[] would be extremely annoying.

@mabruzzo mabruzzo added the refactor internal reorganization or code simplification with no behavior changes label Dec 8, 2025
@mabruzzo mabruzzo force-pushed the ncc/cppify-interp_table_utils branch from 8435f82 to 0cd4082 Compare December 8, 2025 18:07
@mabruzzo mabruzzo changed the base branch from newchem-cpp to main January 13, 2026 22:45
@mabruzzo mabruzzo changed the base branch from main to newchem-cpp January 13, 2026 22:45
@brittonsmith brittonsmith merged commit 7484c12 into grackle-project:newchem-cpp Jan 20, 2026
5 checks passed
@mabruzzo mabruzzo deleted the ncc/cppify-interp_table_utils branch January 20, 2026 15:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

refactor internal reorganization or code simplification with no behavior changes

Projects

Development

Successfully merging this pull request may close these issues.

2 participants