Skip to content

Add support for ignoring suffix characters in numeric conversions#18

Open
nnbox wants to merge 1 commit intofanf2:masterfrom
nnbox:fix/hexadecimal-suffix-support
Open

Add support for ignoring suffix characters in numeric conversions#18
nnbox wants to merge 1 commit intofanf2:masterfrom
nnbox:fix/hexadecimal-suffix-support

Conversation

@nnbox
Copy link
Copy Markdown

@nnbox nnbox commented Apr 16, 2024

Introduce a new function strtol_with_suffix to convert a string to a long integer while allowing for certain suffix characters ('L', 'l', 'U', 'u') to be ignored. This function will return the long integer value from the string, or 0 if no valid conversion can be performed. It updates strtol calls in eval_unary to use this new function, improving handling of numeric inputs with suffixes.

Introduce a new function `strtol_with_suffix` to convert a string to a long integer while allowing for certain suffix characters ('L', 'l', 'U', 'u') to be ignored. This function will return the long integer value from the string, or 0 if no valid conversion can be performed. It updates `strtol` calls in `eval_unary` to use this new function, improving handling of numeric inputs with suffixes.
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