runtime: factor object dumping code out of greyobject
When checkmark fails, greyobject dumps both the object that pointed to the unmarked object and the unmarked object. This code cluttered up greyobject, was copy-pasted for the two objects, and the copy for dumping the unmarked object was not entirely correct. Extract object dumping out to a new function. This declutters greyobject and fixes the bugs in dumping the unmarked object. The new function is slightly cleaned up from the original code to have more natural control flow and shows a marker on the field in the base object that points to the unmarked object to make it easy to find. Change-Id: Ib51318a943f50b0b99995f0941d03ee8876b9fcf Reviewed-on: https://go-review.googlesource.com/7506Reviewed-by: Rick Hudson <rlh@golang.org>
Showing
Please register or sign in to comment