Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/lsif.rs
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,7 @@ pub enum ItemKind {
#[derive(Debug, PartialEq, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct Item {
pub document: Id,
pub shard: Id,
#[serde(skip_serializing_if = "Option::is_none")]
pub property: Option<ItemKind>,
#[serde(flatten)]
Expand Down
36 changes: 18 additions & 18 deletions tests/tsc-unix.lsif
Original file line number Diff line number Diff line change
Expand Up @@ -61,36 +61,36 @@
{"id":61,"type":"edge","label":"next","outV":60,"inV":25}
{"id":62,"type":"vertex","label":"definitionResult"}
{"id":63,"type":"edge","label":"textDocument/definition","outV":6,"inV":62}
{"id":64,"type":"edge","label":"item","outV":62,"inVs":[13],"document":4}
{"id":64,"type":"edge","label":"item","outV":62,"inVs":[13],"shard":4}
{"id":65,"type":"vertex","label":"referenceResult"}
{"id":66,"type":"edge","label":"textDocument/references","outV":6,"inV":65}
{"id":67,"type":"edge","label":"item","outV":65,"inVs":[13],"document":4,"property":"definitions"}
{"id":67,"type":"edge","label":"item","outV":65,"inVs":[13],"shard":4,"property":"definitions"}
{"id":68,"type":"vertex","label":"definitionResult"}
{"id":69,"type":"edge","label":"textDocument/definition","outV":15,"inV":68}
{"id":70,"type":"edge","label":"item","outV":68,"inVs":[21],"document":4}
{"id":70,"type":"edge","label":"item","outV":68,"inVs":[21],"shard":4}
{"id":71,"type":"vertex","label":"referenceResult"}
{"id":72,"type":"edge","label":"textDocument/references","outV":15,"inV":71}
{"id":73,"type":"edge","label":"item","outV":71,"inVs":[21],"document":4,"property":"definitions"}
{"id":73,"type":"edge","label":"item","outV":71,"inVs":[21],"shard":4,"property":"definitions"}
{"id":74,"type":"vertex","label":"definitionResult"}
{"id":75,"type":"edge","label":"textDocument/definition","outV":25,"inV":74}
{"id":76,"type":"edge","label":"item","outV":74,"inVs":[28],"document":4}
{"id":76,"type":"edge","label":"item","outV":74,"inVs":[28],"shard":4}
{"id":77,"type":"vertex","label":"referenceResult"}
{"id":78,"type":"edge","label":"textDocument/references","outV":25,"inV":77}
{"id":79,"type":"edge","label":"item","outV":77,"inVs":[28],"document":4,"property":"definitions"}
{"id":80,"type":"edge","label":"item","outV":77,"inVs":[60],"document":4,"property":"references"}
{"id":79,"type":"edge","label":"item","outV":77,"inVs":[28],"shard":4,"property":"definitions"}
{"id":80,"type":"edge","label":"item","outV":77,"inVs":[60],"shard":4,"property":"references"}
{"id":81,"type":"vertex","label":"definitionResult"}
{"id":82,"type":"edge","label":"textDocument/definition","outV":32,"inV":81}
{"id":83,"type":"edge","label":"item","outV":81,"inVs":[35],"document":4}
{"id":83,"type":"edge","label":"item","outV":81,"inVs":[35],"shard":4}
{"id":84,"type":"vertex","label":"referenceResult"}
{"id":85,"type":"edge","label":"textDocument/references","outV":32,"inV":84}
{"id":86,"type":"edge","label":"item","outV":84,"inVs":[35],"document":4,"property":"definitions"}
{"id":87,"type":"edge","label":"item","outV":84,"inVs":[44],"document":4,"property":"references"}
{"id":86,"type":"edge","label":"item","outV":84,"inVs":[35],"shard":4,"property":"definitions"}
{"id":87,"type":"edge","label":"item","outV":84,"inVs":[44],"shard":4,"property":"references"}
{"id":88,"type":"vertex","label":"referenceResult"}
{"id":89,"type":"edge","label":"textDocument/references","outV":39,"inV":88}
{"id":90,"type":"edge","label":"item","outV":88,"inVs":[42],"document":4,"property":"references"}
{"id":90,"type":"edge","label":"item","outV":88,"inVs":[42],"shard":4,"property":"references"}
{"id":91,"type":"vertex","label":"referenceResult"}
{"id":92,"type":"edge","label":"textDocument/references","outV":48,"inV":91}
{"id":93,"type":"edge","label":"item","outV":91,"inVs":[58],"document":4,"property":"references"}
{"id":93,"type":"edge","label":"item","outV":91,"inVs":[58],"shard":4,"property":"references"}
{"id":94,"type":"vertex","label":"document","uri":"file:///media/hamid/nv1/garbage/b.ts","languageId":"typescript"}
{"id":95,"type":"vertex","label":"$event","kind":"begin","scope":"document","data":94}
{"id":96,"type":"vertex","label":"resultSet"}
Expand All @@ -115,16 +115,16 @@
{"id":115,"type":"edge","label":"next","outV":114,"inV":104}
{"id":116,"type":"vertex","label":"definitionResult"}
{"id":117,"type":"edge","label":"textDocument/definition","outV":96,"inV":116}
{"id":118,"type":"edge","label":"item","outV":116,"inVs":[102],"document":94}
{"id":118,"type":"edge","label":"item","outV":116,"inVs":[102],"shard":94}
{"id":119,"type":"vertex","label":"referenceResult"}
{"id":120,"type":"edge","label":"textDocument/references","outV":96,"inV":119}
{"id":121,"type":"edge","label":"item","outV":119,"inVs":[102],"document":94,"property":"definitions"}
{"id":122,"type":"edge","label":"item","outV":71,"inVs":[108,114],"document":94,"property":"references"}
{"id":123,"type":"edge","label":"item","outV":65,"inVs":[112],"document":94,"property":"references"}
{"id":121,"type":"edge","label":"item","outV":119,"inVs":[102],"shard":94,"property":"definitions"}
{"id":122,"type":"edge","label":"item","outV":71,"inVs":[108,114],"shard":94,"property":"references"}
{"id":123,"type":"edge","label":"item","outV":65,"inVs":[112],"shard":94,"property":"references"}
{"id":124,"type":"vertex","label":"definitionResult"}
{"id":125,"type":"edge","label":"textDocument/definition","outV":48,"inV":124}
{"id":126,"type":"edge","label":"item","outV":124,"inVs":[54],"document":46}
{"id":127,"type":"edge","label":"item","outV":91,"inVs":[54],"document":46,"property":"definitions"}
{"id":126,"type":"edge","label":"item","outV":124,"inVs":[54],"shard":46}
{"id":127,"type":"edge","label":"item","outV":91,"inVs":[54],"shard":46,"property":"definitions"}
{"id":128,"type":"edge","label":"contains","outV":4,"inVs":[13,21,28,35,42,44,58,60]}
{"id":129,"type":"vertex","label":"$event","kind":"end","scope":"document","data":4}
{"id":130,"type":"edge","label":"contains","outV":46,"inVs":[54]}
Expand Down