Skip to content

Cleanup scoplib declarations and remove unused files.#1598

Merged
nrnhines merged 4 commits into
masterfrom
olupton/scoplib-cleanup
Jan 26, 2022
Merged

Cleanup scoplib declarations and remove unused files.#1598
nrnhines merged 4 commits into
masterfrom
olupton/scoplib-cleanup

Conversation

@olupton

@olupton olupton commented Jan 25, 2022

Copy link
Copy Markdown
Collaborator

This is a change from #1597 that seems like a standalone improvement that can be reviewed separately.

This is relevant for C++ migration, because once we compile mechanisms as C++ it will be necessary to have full declarations of these functions that are called from translated code.

Summary of changes:

  • Install newton_struct.h so it can be included from scoplib.h and thereby avoid duplicating declarations.
  • Drop scoplib_ansi.h and update scoplib.h to contain C-and-C++ compatible full declarations of scoplib functions.
  • Drop declarations of functions that are apparently never defined.
  • Make newton_struct.h C-and-C++ compatible, include it in scoplib.h, make its declarations match definitions, move some private details to crout_thread.c and/or newton_thread.c.
  • Delete files src/oc/nocable.cpp and src/oc/ocnoiv.cpp that do not appear to be used anywhere.
  • Do not emit an incorrect declaration for nrn_cons_newtonspace when translating mechanisms, assume the correct declaration will be #include'd.
  • Add ${PROJECT_SOURCE_DIR}/src/scopmath to the include search path.

@olupton olupton marked this pull request as ready for review January 25, 2022 09:49

@nrnhines nrnhines left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very nice improvement. And I'm glad that nocable and ocnoiv are gone. They were relics of when the oc.exe and nrnoc.exe were built as standalone executables.

@olupton olupton changed the title Cleanup scoplib declarations and remove unused files. Cleanup scoplib declarations and remove unused files. [live-debug-docs] Jan 26, 2022
@olupton

olupton commented Jan 26, 2022

Copy link
Copy Markdown
Collaborator Author

The documentation CI failure is giving me some problems as I cannot reproduce the failure locally. Let's try with live-debug..

@olupton olupton closed this Jan 26, 2022
@olupton olupton reopened this Jan 26, 2022
@codecov-commenter

codecov-commenter commented Jan 26, 2022

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 45.16%. Comparing base (edb982e) to head (5ef8ed7).
⚠️ Report is 3091 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #1598   +/-   ##
=======================================
  Coverage   45.16%   45.16%           
=======================================
  Files         551      551           
  Lines      111191   111191           
=======================================
  Hits        50217    50217           
  Misses      60974    60974           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Comment thread src/scopmath/scoplib.h Outdated
@olupton olupton force-pushed the olupton/scoplib-cleanup branch from d805de3 to 5ef8ed7 Compare January 26, 2022 08:26
@olupton olupton changed the title Cleanup scoplib declarations and remove unused files. [live-debug-docs] Cleanup scoplib declarations and remove unused files. Jan 26, 2022

@alexsavulescu alexsavulescu left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚀

@nrnhines nrnhines merged commit 8571223 into master Jan 26, 2022
@nrnhines nrnhines deleted the olupton/scoplib-cleanup branch January 26, 2022 11:34
@olupton olupton mentioned this pull request Feb 1, 2022
6 tasks
@alexsavulescu alexsavulescu mentioned this pull request Mar 22, 2022
15 tasks
olupton added a commit that referenced this pull request May 16, 2022
- This was added in #1598 based on the definition in newton.c, but the
  function generated by mod2c returns void.
- See newton.c:61 in 5988ffe.
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.

4 participants