Closed jrdegreeff closed 2 years ago
Looking at the codecov report, the current getindex
implementation is not used in any of the tests, so this might be an even easier change than I was expecting. I can put together a quick prototype PR if you'd like.
If you have the time that would be great. I guess atomic_symbol
can use the element
field in atoms_data
.
I've had a super busy week, but sitting down now to do this. I'll open a PR momentarily.
There are a couple things that the
System
implementation is missing for it to be fully interchangable with otherAtomsBase
implementations.atomic_symbol(::System, ::Integer)
is not implementedgetindex(::System, ::Integer)
returns a struct with insufficient fields to be useful in the way that iterating over otherAbstractSystem
is useful. Specifically this is a problem in myAtomistic
andDFTK
integration code where I have to have a special case for aSystem
versus anAbstractSystem
. This could be resolved simply by havinggetindex
return anAtomView
(though any current usage ofgetindex
would have to be modified).