[SERVER-489] toString() formats arrays as objects Created: 15/Dec/09  Updated: 12/Jul/16  Resolved: 06/Apr/10

Status: Closed
Project: Core Server
Component/s: Usability
Affects Version/s: None
Fix Version/s: 1.5.0

Type: Bug Priority: Trivial - P5
Reporter: Aaron Staple Assignee: Aaron Staple
Resolution: Done Votes: 1
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Participants:

 Description   

Might be nice to print arrays with square bracket notation. I thought we used to do this, don't know why we changed the behavior (otherwise I'd just fix it myself).

BSONObj o = fromjson( "

{r:[1,2,3]}

" );
log() << "o: " << o << endl;

Tue Dec 15 17:54:05 o: { r:

{ 0: 1, 1: 2, 2: 3 }

}



 Comments   
Comment by Eliot Horowitz (Inactive) [ 26/Apr/10 ]

in a release

Comment by auto [ 06/Apr/10 ]

Author:

{'login': '', 'name': 'Aaron', 'email': 'aaron@10gen.com'}

Message: SERVER-489 toString() foramt arrays as arrays not objects
http://github.com/mongodb/mongo/commit/00f604c06334bad02565e8fc6bb300708d67f395

Comment by Eliot Horowitz (Inactive) [ 26/Feb/10 ]

we should change - but lets do in 1.5.0 just in case

Generated at Thu Feb 08 02:54:16 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.