JuliaPy / JuliaPy/PythonCall.jl

Massively simplify pyconvert?

Offen
#417 2 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
Vorherrschende Sprache
Julia
Sterne
1.1k
Forks
86
Ø Merge
1 T. 22 Std.
Gemergte PRs (30 T.)
3

Beschreibung

Don't take a type, so it's just `pyconvert(::Py)`. Symmetric with `Py(x)` for conversion in the other direction. Will be simpler so define rules and can just run up the MRO to apply them.

Could also have a `override` argument to possibly provide custom conversions (and same for `Py`).

Could additionally support `pyconvert(T, x)` as an alias for `convert(T, pyconvert(x))::T`. Or do something slightly snazzier which lets us skip over rules that cannot apply?

Beitragsleitfaden

Für dieses Repository ist kein Beitragsleitfaden indexiert

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.