Skip to content
Snippets Groups Projects
Commit db27d470 authored by Serge Petrenko's avatar Serge Petrenko Committed by Vladimir Davydov
Browse files

decimal: diallow infinity and NaN entirely.

While arithmetic operations do not return infinities or NaNs, it is
possbile to construct an invalid decimal value from strings 'Infinity',
'NaN' and similar. Some decimal mathematic functions may also result in
an infinity, say, ln(0) yields '-Infinity'.
So, add checks that the number is not a NaN or infinity after each
operation, so that the operation either returns an error, or a valid
finite decimal number.

Follow-up 6d62c6c1
parent e0d4a5dc
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment