Closed brainandforce closed 1 year ago
It appears that this branch is failing checks because of method ambiguities that not only I introduced, but the InlineStrings.jl package introduced. I'll hold off on merging this for now.
Link to the issue I've opened on InlineStrings.jl regarding this problem: https://github.com/JuliaStrings/InlineStrings.jl/issues/64
Previously, the
NamedAtom
struct was defined like such:We used an
NTuple{8,Char}
to store a fixed-length C string so thatNamedAtom
can remain a bits type, and then overloadedBase.getproperty()
and the constructors to deal with the fact that we want to treat the fixed string data as a Julia string. However, the InlineStrings.jl package defines fixed-length strings as their own data type, with all other Julia string operations supported, so this should significantly simplify the code. I've also allowed the name field to hold up to 15 characters, an improvement from the previous 8.On top of that, I've included conversion semantics for
NamedAtom
structs, allowing them to be converted to strings or numbers easily.