AlgebraicJulia / AlgebraicJulia/ACSets.jl
Converting from BasicSchema to TypeLevelSchema
- Vorherrschende Sprache
- Julia
- Sterne
- 36
- Forks
- 11
- PR-Merge-Kennzahlen
- Keine gemergten PRs in 30 T.
Beschreibung
ACSets.jl allows us to go from `TypeLevelSchema` to `BasicSchema`, and I thought at some point I needed to go the other way around and wrote this one-liner:
```julia
""" Convert a Schema to a Type-level schema """
TypeLevelBasicSchema(s::BasicSchema{Name}) where {Name} =
TypeLevelBasicSchema{Name, Tuple{s.obs...}, Tuple{s.homs...},
Tuple{s.attrtypes...}, Tuple{s.attrs...}, Tuple{s.eqs...}}
TypeLevelBasicSchema(s::Type{<:TypeLevelBasicSchema}) = s
```
But then I happened to not need to. Still, this might be a feature that someone wants?
Beitragsleitfaden
Für dieses Repository ist kein Beitragsleitfaden indexiert
Bewertung
Dieses Issue wurde noch nicht bewertet.