Cleanup of C++ core codebase
Created by: paulromano
After #1171 is merged, we no longer have any Fortran code in OpenMC. However, there are still some things that need cleaning up on the C++ side. I wanted to open this issue to keep track of them:
Fix off-by-one indexing. Much of the C API still expects indices based on 1-indexing instead of 0-indexing. As a result, there is a whole bunch of
+1s scattered through the code. We should consistently use 0-indexing now that there is no Fortran.
Directionclasses (mostly as part of the
Particle::initializemethod should probably be part of a constructor?
See if we can get rid of
- Use the GSL library for spans (to replace pointer/length pairs in interfaces) and asserts
Use trailing underscore for class data members consistently (especially
enum classwhere it makes sense
unique_ptrinstead of raw pointers in global vectors
If any of you guys have other things in mind that I'm missing, feel free to add to the list.