标签: json go
我有这样的JSON数组
[{"attribute":"a","privilege":{"read":true,"write":true}},{},{},{}...]
我希望将其转换为Map
{"a":{"read":true,"write":true}, "b":{"read":true,"write":true}, , , }
我该如何在golang中做到这一点。