diff options
| author | Dylan DPC <dylan.dpc@gmail.com> | 2020-04-20 18:07:09 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-04-20 18:07:09 +0200 |
| commit | 314b78c5502cc232b975a5ce8870f61c5902ad47 (patch) | |
| tree | 60c129db565535407284e006d364fe01066726c1 /src/test/rustdoc-ui/coverage/json.rs | |
| parent | e80d30347ab9dc2e4f73a9f3c8cc3bf09914a597 (diff) | |
| parent | b469d2db6dc7329dcf7a1a42e2111b46da818b9a (diff) | |
| download | rust-314b78c5502cc232b975a5ce8870f61c5902ad47.tar.gz rust-314b78c5502cc232b975a5ce8870f61c5902ad47.zip | |
Rollup merge of #71284 - JOE1994:serialize_id, r=petrochenkov
fix -Zast-json to output correct JSON form
fixes #71086 (Reverts some of the changes made in #70215)
JSON output (from an empty library) after fix has something for **"id"** field
```shell
lonelyjoe@lonelyjoe-desktop:~/workspace/empty_lib/src$ rustc lib.rs -Zast-json
```
```json
{
"module":{
"inner":{
"lo":0,
"hi":94
},
"items":[
{
"attrs":[
{
"kind":{
"variant":"Normal",
"fields":[
{
"path":{
"span":{
"lo":0,
"hi":0
},
"segments":[
{
"ident":{
"name":"prelude_import",
"span":{
"lo":0,
"hi":0
}
},
"id":3,
"args":null
}
]
},
"args":"Empty"
}
]
},
"id":null,
"style":"Outer",
"span":{
"lo":0,
"hi":0
}
}
],
"id":4,
"span":{
"lo":0,
"hi":0
},
"vis":{
"node":"Inherited",
"span":{
"lo":0,
"hi":0
}
},
"ident":{
"name":"",
"span":{
"lo":0,
"hi":0
}
},
"kind":{
"variant":"Use",
"fields":[
{
"prefix":{
"span":{
"lo":0,
"hi":0
},
"segments":[
{
"ident":{
"name":"{{root}}",
"span":{
"lo":0,
"hi":0
}
},
"id":5,
"args":null
},
{
"ident":{
"name":"std",
"span":{
"lo":0,
"hi":0
}
},
"id":6,
"args":null
},
{
"ident":{
"name":"prelude",
"span":{
"lo":0,
"hi":0
}
},
"id":7,
"args":null
},
{
"ident":{
"name":"v1",
"span":{
"lo":0,
"hi":0
}
},
"id":8,
"args":null
}
]
},
"kind":"Glob",
"span":{
"lo":0,
"hi":0
}
}
]
},
"tokens":null
},
{
"attrs":[
{
"kind":{
"variant":"Normal",
"fields":[
{
"path":{
"span":{
"lo":0,
"hi":0
},
"segments":[
{
"ident":{
"name":"macro_use",
"span":{
"lo":0,
"hi":0
}
},
"id":9,
"args":null
}
]
},
"args":"Empty"
}
]
},
"id":null,
"style":"Outer",
"span":{
"lo":0,
"hi":0
}
}
],
"id":10,
"span":{
"lo":0,
"hi":0
},
"vis":{
"node":"Inherited",
"span":{
"lo":0,
"hi":0
}
},
"ident":{
"name":"std",
"span":{
"lo":0,
"hi":0
}
},
"kind":{
"variant":"ExternCrate",
"fields":[
null
]
},
"tokens":null
}
],
"inline":true
},
"attrs":[
],
"span":{
"lo":0,
"hi":94
},
"proc_macros":[
]
}
```
Diffstat (limited to 'src/test/rustdoc-ui/coverage/json.rs')
0 files changed, 0 insertions, 0 deletions
