samujjwal / google-gson

Automatically exported from code.google.com/p/google-gson
0 stars 0 forks source link

Boolean no error passing a String value #600

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
passing a number to a Boolean I see the error: Expected a boolean but was 
NUMBER (OK), passing a string to a Boolean there is no error and is assigned to 
the Boolean false (NOT OK)

{"isPRA":10}     generate the error (OK)

{"isPRA":"ABC"}  no error (NOT OK)

In the example isPRA is a Boolean field and I used gson 2.3

Original issue reported on code.google.com by dmclcu57...@gmail.com on 14 Oct 2014 at 9:06