Details
-
Type:
Bug
-
Status:
Closed
-
Priority:
Minor
-
Resolution: Fixed
-
Affects Version/s: 1.8.0, 1.8.1
-
Fix Version/s: 1.8.2, 1.9-beta-3
-
Component/s: groovy-jdk
-
Labels:None
-
Testcase included:yes
-
Number of attachments :
Description
Currently
will outputprintln new JsonBuilder(['a','b','c','d'] as char[]).toString()
since the primitive class char has no properties (other than class).[{},{},{},{}]
My solution is to call toString on the object if there are no properties left. I have attached an updated JsonOutput.groovy and a fixed test.
Activity
Guillaume Laforge
made changes -
| Field | Original Value | New Value |
|---|---|---|
| Assignee | Guillaume Laforge [ guillaume ] |
Seth Miller
made changes -
| Attachment | GROOVY-4984.patch [ 56611 ] |
Guillaume Laforge
made changes -
| Fix Version/s | 1.8.2 [ 17495 ] | |
| Fix Version/s | 1.9-beta-2 [ 17494 ] |
Guillaume Laforge
made changes -
| Status | Open [ 1 ] | Resolved [ 5 ] |
| Resolution | Fixed [ 1 ] |
Paul King
made changes -
| Status | Resolved [ 5 ] | Closed [ 6 ] |
Here is a patch file with my changes, if that helps.