floss: dbus_macros: Call DBusArg::log to elements and revise {:?} usage
- In container types (Option, Vec, HashMap) call DBusArg::log to the elements so we can control how these elements would be printed. - Avoid using Debug format "{:?}" in the containers and the toppest DBusLog::log, because that recursively produces many backslashes. - Use |vertical bar| to separate different DBus args. - Use Debug format "{:?}" for the base types (e.g. String) so it's easier to realize the type from the log. Before this CL: RegisterClient: "e060b902508c485f8b0e27639c7f2d41", "Box<dyn>", "false" * The first arg is a String, but we can't distinguish it CreateInsecureRfcommSocketToServiceRecord: "8", "BluetoothDevice { address: \"xx:xx:xx:xx:8a:48\", name: \"\" }", "a384bd4f-41ea-3b02-8901-8c2ed9a79970" * The double quotes make it hard to know which chunk is a single arg * The third arg is a Uuid VS after: RegisterClient: |"e060b902508c485f8b0e27639c7f2d41"|, |Box<dyn>|, |false| CreateInsecureRfcommSocketToServiceRecord: |8|, |BluetoothDevice { address: xx:xx:xx:xx:8a:48, name: "" }|, |a384bd4f-41ea-3b02-8901-8c2ed9a79970| Bug: 342337056 Tag: #floss Test: mmm packages/modules/Bluetooth Test: manual Toggle BT, verify the log Flag: EXEMPT, Floss-only changes Change-Id: If7e0d65eebbaaa27e72e14ca1901c37a59fbdccf
Loading
Please register or sign in to comment