Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

如果 Bean 里面字段类型是 LinkedHashMap<Integer, Number> 的话,Number 里面如果出现浮点型数值,还是会被转为 BigDecimal #3326

Closed
asdf2014 opened this issue Jul 3, 2020 · 3 comments
Assignees
Labels
Milestone

Comments

@asdf2014
Copy link

asdf2014 commented Jul 3, 2020

使用 JSON.DEFAULT_PARSER_FEATURE &= ~Feature.UseBigDecimal.getMask() 方式,正常是可以避免 double 转 BigDecimal 的,但是如果 Bean 里面字段类型是 LinkedHashMap<Integer, Number> 的话,Number 里面如果出现浮点型数值,还是会被转为 BigDecimal

image

版本:1.2.70

@asdf2014
Copy link
Author

asdf2014 commented Jul 3, 2020

@wenshao PTAL

@wenshao wenshao added this to the 1.2.73 milestone Jul 4, 2020
@wenshao wenshao self-assigned this Jul 4, 2020
@wenshao wenshao added the bug label Jul 4, 2020
@wenshao
Copy link
Member

wenshao commented Jul 26, 2020

https://github.com/alibaba/fastjson/releases/tag/1.2.73
问题修复,请用新版本

@wenshao wenshao closed this as completed Jul 26, 2020
@asdf2014
Copy link
Author

@wenshao 赞啊,感谢大佬 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants