Catch unsupported elements#189
Catch unsupported elements#189marvinfriede merged 5 commits intodftd4:mainfrom marvinfriede:exit-unsupported-elements
Conversation
marvinfriede
commented
Feb 5, 2023
- exit if elements between 87 (Fr) and 111 (Rg) are in the structure
- catch unsupported reference charge option instead of implicitly using EEQ charges
Codecov Report
@@ Coverage Diff @@
## main #189 +/- ##
==========================================
+ Coverage 42.44% 42.79% +0.34%
==========================================
Files 31 31
Lines 2554 2636 +82
Branches 1047 1094 +47
==========================================
+ Hits 1084 1128 +44
- Misses 957 971 +14
- Partials 513 537 +24
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
awvwgk
left a comment
There was a problem hiding this comment.
The error handle best goes first or last in the argument list. Also, can we avoid breaking the Fortran API by providing a compatibility subroutine with the old signature?
Would it then be better to check before calling However, this would not cover the error check for the reference charge option. I could change the error to an info. if (ref_charge == d4_ref%gfn2) then
do isp = 1, mol%nid
izp = mol%num(isp)
call set_refq_gfn2(self%q(:, isp), izp)
call set_refalpha_gfn2(self%aiw(:, :, isp), self%ga, self%gc, izp)
end do
else
if (ref_charge /= d4_ref%eeq) then
write(output_unit, '(a)') "[Info] Unsupported option for reference charges. Defaulting to EEQ charges."
end if
do isp = 1, mol%nid
izp = mol%num(isp)
call set_refq_eeq(self%q(:, isp), izp)
call set_refalpha_eeq(self%aiw(:, :, isp), self%ga, self%gc, izp)
end do
end if |
|
Since I think that the check should be within I also added the info from the above comment to the old version. |
awvwgk
left a comment
There was a problem hiding this comment.
Looks good to me, one minor comment regarding the dllexport, but I'm no expert there.