-
Notifications
You must be signed in to change notification settings - Fork 127
Refactor name mangling in NMODL ODE solver #3543
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
✔️ 225cc45 -> Azure artifacts URL |
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #3543 +/- ##
==========================================
+ Coverage 68.49% 68.66% +0.17%
==========================================
Files 685 685
Lines 116720 116711 -9
==========================================
+ Hits 79944 80141 +197
+ Misses 36776 36570 -206 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
✔️ 225cc45 -> artifacts URL |
✔️ d9e3d17 -> artifacts URL |
✔️ d9e3d17 -> Azure artifacts URL |
Put back whatever hackery it used before to collect the mod files, if some of the files are missing coverage I really don't care.
also add comment about using single triple quotes
…lic/refactor_coverage
✔️ 6059fe5 -> Azure artifacts URL |
✔️ 6059fe5 -> artifacts URL |
✔️ 6a464cf -> Azure artifacts URL |
✔️ 6a464cf -> artifacts URL |
✔️ 2a6d889 -> artifacts URL |
✔️ 2a6d889 -> Azure artifacts URL |
✔️ 8940991 -> artifacts URL |
✔️ 8940991 -> Azure artifacts URL |
✔️ 2b2f315 -> Azure artifacts URL |
✔️ 2b2f315 -> artifacts URL |
✔️ b54d8d5 -> Azure artifacts URL |
✔️ b54d8d5 -> artifacts URL |
|
✔️ b611c56 -> artifacts URL |
✔️ b611c56 -> Azure artifacts URL |
Needs #3544.
Fixes #3414.
NMODL's previous way of handling identifiers was somewhat convoluted; this PR introduces 2 functions,
mangle_protected_identifiers
, and its inverse,demangle_protected_identifiers
, which should accomplish the same thing, in much less lines of code. The name mangling is achieved via a regex (same way as before), but this time is generalized for:sin
,cos
, etc.)Also sprinkled in some type hints.
Also added
test_ode.py
to coverage collection.This allows us to build NEURON with
NRN_ENABLE_NMODL=ON
.TODO
integrate2c
(was not using[de]mangle_identifiers
before)