(gdb)
-break-insert foobar
^done,bkpt={number="1",type="breakpoint",disp="keep",enabled="
y",addr="<MULTIPLE>",times="0",original-location="foobar"},{nu
mber="1.1",enabled="y",addr="0x00000000004008d7",func="foobar()",file="overload.cpp",fullname=".../src/test-bktp-mi-> overload/overload.cpp",line="22",thread-groups=["i1"]},{number
="1.2",enabled="y",addr="0x00000000004008e0",func="foobar(int)",file="overload.cpp",fullname=".../src/test-bktp-mi-> overload/overload.cpp",line="26",thread-groups=["i1"]}
(gdb)
So no square brackets. Therefore not a list and IMHO not a
valid MI output.
You're right. The output I took was from -break-list, but
for -break-insert, and probably some others, this does not
look to be valid syntax.
I like your proposal of
bkpt={number="1", ... , locations=[{number="1.1", ...}, ...]}
which would allow to easily differentiate between the "main bp
entry" and the "sub entries".