Skip to content

fix: handle negative Vietnamese cardinals without corrupting words#674

Open
santhreal wants to merge 1 commit into
savoirfairelinux:masterfrom
santhreal:fix/vi-negative-cardinal
Open

fix: handle negative Vietnamese cardinals without corrupting words#674
santhreal wants to merge 1 commit into
savoirfairelinux:masterfrom
santhreal:fix/vi-negative-cardinal

Conversation

@santhreal

@santhreal santhreal commented Jul 18, 2026

Copy link
Copy Markdown

lang_VI.number_to_text hits DataLoss/IndexError when negative int indexes to_19 from end producing wrong words or crash. This PR fixes the regression with a focused test covering the case.

Negative values indexed to_19 from the end (e.g. -1 became mười chín).
Prefix with âm and convert the absolute value.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant