[Rust] Add an option to use Rust native enum
I maintainer di solito rispondono entro 1 giorno
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 35/100
Direzione di ricerca
The issue concerns the #[ForyUnon] attribute on Rust enums and the rule that picks the xlang union representation when a variant has 2+ fields. Start by finding where that attribute and the field-count check are handled in the Rust derive code, and decide how a user-facing option should select the native enum instead. Done means a user can choose native enum output explicitly, without an Unknown variant, with the choice covered by tests. The design of the option's name and behaviour should be agreed with maintainers first.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Feature Request
#[ForyUnon] enum T { .. } can be
- Xlang union, which requires me to add
Unknownvariant - Rust native enum, which does not require me to
Unknownvariant
The problem is that there is no way to tell Fory to use 2.
It's automatically decided by the existence of a variant with 2+ fields.
Is your feature request related to a problem? Please describe
No response
Describe the solution you'd like
No response
Describe alternatives you've considered
No response
Additional context
No response
- Lingua principale
- Java
- Stelle
- 4.6k
- Fork
- 470
- Merge medio
- 9h 28m
- PR unite (30g)
- 33
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Ha un modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di apache/fory
-
[Python] Compatible xlang read silently drops fields when the peer writes camelCase/PascalCase namesAperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 85/100
I maintainer di solito rispondono entro 1 giorno
-
[Build] Add ASF license headers to config files that allow commentsForse di nuovo libera @Swatantra-66 l’ha presa 27 giorni fa e non c’è nessuna pull request aperta. Apertaenhancement
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
apache/fory#4124 · 3 commenti ·
I maintainer di solito rispondono entro 1 giorno
-
xlang: the snake_case conversion of field names is not specified, and the runtimes do not agreeForse di nuovo libera @dhruv-dagar l’ha presa 14 giorni fa e non c’è nessuna pull request aperta. Apertabug
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
apache/fory#4187 · 2 commenti ·
I maintainer di solito rispondono entro 1 giorno
-
Untyped read collapses a number literal that does not fit a doubleForse già presa @mohitjoshi-hey l’ha presa 20 giorni fa. Apertabug
Difficoltà 3/5 1-2 giorni Idoneità per principianti 68/100
apache/fory#4170 · 3 commenti · 1 assegnatario ·
I maintainer di solito rispondono entro 1 giorno
-
Registered factory cannot tell a field from the root of the callForse già presa @mohitjoshi-hey l’ha presa 17 giorni fa. Apertabug
Difficoltà 4/5 1-2 giorni Idoneità per principianti 48/100
apache/fory#4169 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
I maintainer di solito rispondono entro 3 giorni
-
A proxy that fails to start logs a RejectedExecutionException stack trace from its shutdown hookApertafollow-up
Difficoltà 2/5 1-3 ore Idoneità per principianti 62/100
Sanne/incus-spawn#1953 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
atlassian/data-center-helm-charts#1170 ·
I maintainer di solito rispondono entro 1 giorno
-
Bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
I maintainer di solito rispondono entro 1 giorno
-
Issue: Bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 62/100
OpenAPITools/openapi-generator#25524 ·
I maintainer di solito rispondono entro 1 giorno