-
Notifications
You must be signed in to change notification settings - Fork 79
[new-hs-indexer #4] New Haskell Indexer #511
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
✅ Deploy Preview for fb-oss-glean canceled.
|
|
Something's broken in glass |
|
@jjuliamolin has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
|
Thanks Simon this is great :) I'll have a look at this one, will need to fix some internal dependencies |
|
@jjuliamolin you probably want to re-import, I just pushed a new version of this branch with:
Note: stacked on #514 |
|
It's going to be quite tricky to merge this as it requires changes to internal TARGETS files. Can you fix the CI errors @simonmar and let us know when to reimport? |
|
@jjuliamolin has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
|
I'll import a temporary one to check the internal build targets, will re-import again if there's CI signals to fix here |
|
Alright, it looks like the failures are:
|
3d106fe to
8f49a6b
Compare
|
@jjuliamolin @pepeiborra OK, CI is green. I'm sure this is going to be non-trivial to get working with the internal build system so no worries if it takes a while! I'm not in a rush to get it landed. I'll stop modifying this PR so that you have something stable to work with and create separate PRs for future changes, although note that I'll have to stack new PRs on top of this one. |
|
@jjuliamolin has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
|
Sorry that this is taking longer than anticipated.. We're close to landing it internally, but I found some backward incompatibilities from the generated schema thrift files: Module_key in hs.thrift SourceModule_key in hs.thrift SearchByName_key search_hs.thrift Can you take a look @simonmar, maybe we need evolve there, in the angle schemas Also I noticed there's a bug somewhere that creates build errors for us when Entity = Pred , instead of {p = P }, from code.hs if you want to land faster it might be worth just changing this.. |
you can ignore errors from the Thrift linter about backward-incompatibilities in the Thrift files generated from the schema, they aren't relevant to Glean because Glean has its own backwards-compatibility handling for schemas. As long as the schema passes the validation check, we're all good.
could you give more details? What fails and what is the error? |
|
Ah alright great, wasn't sure what the consequences could be..
it's coming from the types_cpp_splits in targets file generated by haven't had a closer look, but guess we'll just need to change how we count predicates there |
OK, so something weird with compiling the generated Thrift file to C++, which wouldn't show up in the OSS build because we don't do that. If this is due to |
Avoids some cases where the Glean inferred type can diverge from the type expected at the call site.
It didn't work
Redesigned the schema and rewrote the indexer. Compared with the previous indexer: * this captures a lot more xrefs (e.g. local variables) * it has more information (distinguishes functions/classes/constructors etc.) * it is much simpler and probably faster, because it doesn't go via hiedb, it reads .hie files directly. * it is probably more correct, I fixed a lot of things. The schema is carefully designed so that a Name uniquely identifies an entity and corresponds fairly closely to GHC's Name, including OccName. The main difference is we don't store Uniques, instead we distinguish local Names by including their ByteSpan. There are a couple of snapshot tests, one for the plain indexer and one for the codemarkup layer. Not done yet: * Removing all the old stuff * more Glass integration, e.g. Symbol ID * we can extract types from the .hie file too, and provide type hovers in Glass. That wouldn't be too hard. * extracting more structure so that we can reconstruct data/class decls should be possible but it's not straightforward using .hie. I'm still thinking about how best to do that.
Seems to be some issue with record field assignments, I couldn't repro it with a standalone test but it showed up when I indexed all of Glean. The hie file has a reference but no definition for the name.
|
@jjuliamolin I fixed that issue, and also rebased the whole stack (and added a couple more commits at the bottom). All the PRs are numbered - e.g. this one is |
|
@jjuliamolin has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
Summary: Redesigned the schema and rewrote the indexer. Compared with the previous indexer: * this captures a lot more xrefs (e.g. local variables) * it has more information (distinguishes functions/classes/constructors etc.) * it is much simpler and probably faster, because it doesn't go via hiedb, it reads .hie files directly. * it is probably more correct, I fixed a lot of things. The schema is carefully designed so that a Name uniquely identifies an entity and corresponds fairly closely to GHC's Name, including OccName. The main difference is we don't store Uniques, instead we distinguish local Names by including their ByteSpan. There are a couple of snapshot tests, one for the plain indexer and one for the codemarkup layer, and a Glass regression test. Not done yet: * we can extract types from the .hie file too, and provide type hovers in Glass. That wouldn't be too hard. * extracting more structure so that we can reconstruct data/class decls should be possible but it's not straightforward using .hie. I'm still thinking about how best to do that. X-link: facebookincubator/Glean#511 Reviewed By: rubmary Differential Revision: D74400980 Pulled By: jjuliamolin fbshipit-source-id: 6cb183b96ef1c7030c8b7278434f84a4d72ceb28
Summary: Redesigned the schema and rewrote the indexer. Compared with the previous indexer: * this captures a lot more xrefs (e.g. local variables) * it has more information (distinguishes functions/classes/constructors etc.) * it is much simpler and probably faster, because it doesn't go via hiedb, it reads .hie files directly. * it is probably more correct, I fixed a lot of things. The schema is carefully designed so that a Name uniquely identifies an entity and corresponds fairly closely to GHC's Name, including OccName. The main difference is we don't store Uniques, instead we distinguish local Names by including their ByteSpan. There are a couple of snapshot tests, one for the plain indexer and one for the codemarkup layer, and a Glass regression test. Not done yet: * we can extract types from the .hie file too, and provide type hovers in Glass. That wouldn't be too hard. * extracting more structure so that we can reconstruct data/class decls should be possible but it's not straightforward using .hie. I'm still thinking about how best to do that. X-link: facebookincubator/Glean#511 Reviewed By: rubmary Differential Revision: D74400980 Pulled By: jjuliamolin fbshipit-source-id: 6cb183b96ef1c7030c8b7278434f84a4d72ceb28
Summary: Redesigned the schema and rewrote the indexer. Compared with the previous indexer: * this captures a lot more xrefs (e.g. local variables) * it has more information (distinguishes functions/classes/constructors etc.) * it is much simpler and probably faster, because it doesn't go via hiedb, it reads .hie files directly. * it is probably more correct, I fixed a lot of things. The schema is carefully designed so that a Name uniquely identifies an entity and corresponds fairly closely to GHC's Name, including OccName. The main difference is we don't store Uniques, instead we distinguish local Names by including their ByteSpan. There are a couple of snapshot tests, one for the plain indexer and one for the codemarkup layer, and a Glass regression test. Not done yet: * we can extract types from the .hie file too, and provide type hovers in Glass. That wouldn't be too hard. * extracting more structure so that we can reconstruct data/class decls should be possible but it's not straightforward using .hie. I'm still thinking about how best to do that. X-link: facebookincubator/Glean#511 Reviewed By: rubmary Differential Revision: D74400980 Pulled By: jjuliamolin fbshipit-source-id: 6cb183b96ef1c7030c8b7278434f84a4d72ceb28
Summary: Redesigned the schema and rewrote the indexer. Compared with the previous indexer: * this captures a lot more xrefs (e.g. local variables) * it has more information (distinguishes functions/classes/constructors etc.) * it is much simpler and probably faster, because it doesn't go via hiedb, it reads .hie files directly. * it is probably more correct, I fixed a lot of things. The schema is carefully designed so that a Name uniquely identifies an entity and corresponds fairly closely to GHC's Name, including OccName. The main difference is we don't store Uniques, instead we distinguish local Names by including their ByteSpan. There are a couple of snapshot tests, one for the plain indexer and one for the codemarkup layer, and a Glass regression test. Not done yet: * we can extract types from the .hie file too, and provide type hovers in Glass. That wouldn't be too hard. * extracting more structure so that we can reconstruct data/class decls should be possible but it's not straightforward using .hie. I'm still thinking about how best to do that. X-link: facebookincubator/Glean#511 Reviewed By: rubmary Differential Revision: D74400980 Pulled By: jjuliamolin fbshipit-source-id: 6cb183b96ef1c7030c8b7278434f84a4d72ceb28
Summary: Redesigned the schema and rewrote the indexer. Compared with the previous indexer: * this captures a lot more xrefs (e.g. local variables) * it has more information (distinguishes functions/classes/constructors etc.) * it is much simpler and probably faster, because it doesn't go via hiedb, it reads .hie files directly. * it is probably more correct, I fixed a lot of things. The schema is carefully designed so that a Name uniquely identifies an entity and corresponds fairly closely to GHC's Name, including OccName. The main difference is we don't store Uniques, instead we distinguish local Names by including their ByteSpan. There are a couple of snapshot tests, one for the plain indexer and one for the codemarkup layer, and a Glass regression test. Not done yet: * we can extract types from the .hie file too, and provide type hovers in Glass. That wouldn't be too hard. * extracting more structure so that we can reconstruct data/class decls should be possible but it's not straightforward using .hie. I'm still thinking about how best to do that. X-link: facebookincubator/Glean#511 Reviewed By: rubmary Differential Revision: D74400980 Pulled By: jjuliamolin fbshipit-source-id: 6cb183b96ef1c7030c8b7278434f84a4d72ceb28
Summary: Redesigned the schema and rewrote the indexer. Compared with the previous indexer: * this captures a lot more xrefs (e.g. local variables) * it has more information (distinguishes functions/classes/constructors etc.) * it is much simpler and probably faster, because it doesn't go via hiedb, it reads .hie files directly. * it is probably more correct, I fixed a lot of things. The schema is carefully designed so that a Name uniquely identifies an entity and corresponds fairly closely to GHC's Name, including OccName. The main difference is we don't store Uniques, instead we distinguish local Names by including their ByteSpan. There are a couple of snapshot tests, one for the plain indexer and one for the codemarkup layer, and a Glass regression test. Not done yet: * we can extract types from the .hie file too, and provide type hovers in Glass. That wouldn't be too hard. * extracting more structure so that we can reconstruct data/class decls should be possible but it's not straightforward using .hie. I'm still thinking about how best to do that. X-link: facebookincubator/Glean#511 Reviewed By: rubmary Differential Revision: D74400980 Pulled By: jjuliamolin fbshipit-source-id: 6cb183b96ef1c7030c8b7278434f84a4d72ceb28
Summary: Redesigned the schema and rewrote the indexer. Compared with the previous indexer: * this captures a lot more xrefs (e.g. local variables) * it has more information (distinguishes functions/classes/constructors etc.) * it is much simpler and probably faster, because it doesn't go via hiedb, it reads .hie files directly. * it is probably more correct, I fixed a lot of things. The schema is carefully designed so that a Name uniquely identifies an entity and corresponds fairly closely to GHC's Name, including OccName. The main difference is we don't store Uniques, instead we distinguish local Names by including their ByteSpan. There are a couple of snapshot tests, one for the plain indexer and one for the codemarkup layer, and a Glass regression test. Not done yet: * we can extract types from the .hie file too, and provide type hovers in Glass. That wouldn't be too hard. * extracting more structure so that we can reconstruct data/class decls should be possible but it's not straightforward using .hie. I'm still thinking about how best to do that. X-link: facebookincubator/Glean#511 Reviewed By: rubmary Differential Revision: D74400980 Pulled By: jjuliamolin fbshipit-source-id: 6cb183b96ef1c7030c8b7278434f84a4d72ceb28
Summary: Redesigned the schema and rewrote the indexer. Compared with the previous indexer: * this captures a lot more xrefs (e.g. local variables) * it has more information (distinguishes functions/classes/constructors etc.) * it is much simpler and probably faster, because it doesn't go via hiedb, it reads .hie files directly. * it is probably more correct, I fixed a lot of things. The schema is carefully designed so that a Name uniquely identifies an entity and corresponds fairly closely to GHC's Name, including OccName. The main difference is we don't store Uniques, instead we distinguish local Names by including their ByteSpan. There are a couple of snapshot tests, one for the plain indexer and one for the codemarkup layer, and a Glass regression test. Not done yet: * we can extract types from the .hie file too, and provide type hovers in Glass. That wouldn't be too hard. * extracting more structure so that we can reconstruct data/class decls should be possible but it's not straightforward using .hie. I'm still thinking about how best to do that. X-link: facebookincubator/Glean#511 Reviewed By: rubmary Differential Revision: D74400980 Pulled By: jjuliamolin fbshipit-source-id: 6cb183b96ef1c7030c8b7278434f84a4d72ceb28
Summary: Redesigned the schema and rewrote the indexer. Compared with the previous indexer: * this captures a lot more xrefs (e.g. local variables) * it has more information (distinguishes functions/classes/constructors etc.) * it is much simpler and probably faster, because it doesn't go via hiedb, it reads .hie files directly. * it is probably more correct, I fixed a lot of things. The schema is carefully designed so that a Name uniquely identifies an entity and corresponds fairly closely to GHC's Name, including OccName. The main difference is we don't store Uniques, instead we distinguish local Names by including their ByteSpan. There are a couple of snapshot tests, one for the plain indexer and one for the codemarkup layer, and a Glass regression test. Not done yet: * we can extract types from the .hie file too, and provide type hovers in Glass. That wouldn't be too hard. * extracting more structure so that we can reconstruct data/class decls should be possible but it's not straightforward using .hie. I'm still thinking about how best to do that. X-link: facebookincubator/Glean#511 Reviewed By: rubmary Differential Revision: D74400980 Pulled By: jjuliamolin fbshipit-source-id: 6cb183b96ef1c7030c8b7278434f84a4d72ceb28
Summary: Redesigned the schema and rewrote the indexer. Compared with the previous indexer: * this captures a lot more xrefs (e.g. local variables) * it has more information (distinguishes functions/classes/constructors etc.) * it is much simpler and probably faster, because it doesn't go via hiedb, it reads .hie files directly. * it is probably more correct, I fixed a lot of things. The schema is carefully designed so that a Name uniquely identifies an entity and corresponds fairly closely to GHC's Name, including OccName. The main difference is we don't store Uniques, instead we distinguish local Names by including their ByteSpan. There are a couple of snapshot tests, one for the plain indexer and one for the codemarkup layer, and a Glass regression test. Not done yet: * we can extract types from the .hie file too, and provide type hovers in Glass. That wouldn't be too hard. * extracting more structure so that we can reconstruct data/class decls should be possible but it's not straightforward using .hie. I'm still thinking about how best to do that. X-link: facebookincubator/Glean#511 Reviewed By: rubmary Differential Revision: D74400980 Pulled By: jjuliamolin fbshipit-source-id: 6cb183b96ef1c7030c8b7278434f84a4d72ceb28
Summary: Redesigned the schema and rewrote the indexer. Compared with the previous indexer: * this captures a lot more xrefs (e.g. local variables) * it has more information (distinguishes functions/classes/constructors etc.) * it is much simpler and probably faster, because it doesn't go via hiedb, it reads .hie files directly. * it is probably more correct, I fixed a lot of things. The schema is carefully designed so that a Name uniquely identifies an entity and corresponds fairly closely to GHC's Name, including OccName. The main difference is we don't store Uniques, instead we distinguish local Names by including their ByteSpan. There are a couple of snapshot tests, one for the plain indexer and one for the codemarkup layer, and a Glass regression test. Not done yet: * we can extract types from the .hie file too, and provide type hovers in Glass. That wouldn't be too hard. * extracting more structure so that we can reconstruct data/class decls should be possible but it's not straightforward using .hie. I'm still thinking about how best to do that. X-link: facebookincubator/Glean#511 Reviewed By: rubmary Differential Revision: D74400980 Pulled By: jjuliamolin fbshipit-source-id: 6cb183b96ef1c7030c8b7278434f84a4d72ceb28
Summary: Redesigned the schema and rewrote the indexer. Compared with the previous indexer: * this captures a lot more xrefs (e.g. local variables) * it has more information (distinguishes functions/classes/constructors etc.) * it is much simpler and probably faster, because it doesn't go via hiedb, it reads .hie files directly. * it is probably more correct, I fixed a lot of things. The schema is carefully designed so that a Name uniquely identifies an entity and corresponds fairly closely to GHC's Name, including OccName. The main difference is we don't store Uniques, instead we distinguish local Names by including their ByteSpan. There are a couple of snapshot tests, one for the plain indexer and one for the codemarkup layer, and a Glass regression test. Not done yet: * we can extract types from the .hie file too, and provide type hovers in Glass. That wouldn't be too hard. * extracting more structure so that we can reconstruct data/class decls should be possible but it's not straightforward using .hie. I'm still thinking about how best to do that. X-link: facebookincubator/Glean#511 Reviewed By: rubmary Differential Revision: D74400980 Pulled By: jjuliamolin fbshipit-source-id: 6cb183b96ef1c7030c8b7278434f84a4d72ceb28
Summary: Redesigned the schema and rewrote the indexer. Compared with the previous indexer: * this captures a lot more xrefs (e.g. local variables) * it has more information (distinguishes functions/classes/constructors etc.) * it is much simpler and probably faster, because it doesn't go via hiedb, it reads .hie files directly. * it is probably more correct, I fixed a lot of things. The schema is carefully designed so that a Name uniquely identifies an entity and corresponds fairly closely to GHC's Name, including OccName. The main difference is we don't store Uniques, instead we distinguish local Names by including their ByteSpan. There are a couple of snapshot tests, one for the plain indexer and one for the codemarkup layer, and a Glass regression test. Not done yet: * we can extract types from the .hie file too, and provide type hovers in Glass. That wouldn't be too hard. * extracting more structure so that we can reconstruct data/class decls should be possible but it's not straightforward using .hie. I'm still thinking about how best to do that. X-link: facebookincubator/Glean#511 Reviewed By: rubmary Differential Revision: D74400980 Pulled By: jjuliamolin fbshipit-source-id: 6cb183b96ef1c7030c8b7278434f84a4d72ceb28
Summary: Redesigned the schema and rewrote the indexer. Compared with the previous indexer: * this captures a lot more xrefs (e.g. local variables) * it has more information (distinguishes functions/classes/constructors etc.) * it is much simpler and probably faster, because it doesn't go via hiedb, it reads .hie files directly. * it is probably more correct, I fixed a lot of things. The schema is carefully designed so that a Name uniquely identifies an entity and corresponds fairly closely to GHC's Name, including OccName. The main difference is we don't store Uniques, instead we distinguish local Names by including their ByteSpan. There are a couple of snapshot tests, one for the plain indexer and one for the codemarkup layer, and a Glass regression test. Not done yet: * we can extract types from the .hie file too, and provide type hovers in Glass. That wouldn't be too hard. * extracting more structure so that we can reconstruct data/class decls should be possible but it's not straightforward using .hie. I'm still thinking about how best to do that. X-link: facebookincubator/Glean#511 Reviewed By: rubmary Differential Revision: D74400980 Pulled By: jjuliamolin fbshipit-source-id: 6cb183b96ef1c7030c8b7278434f84a4d72ceb28
Summary: Redesigned the schema and rewrote the indexer. Compared with the previous indexer: * this captures a lot more xrefs (e.g. local variables) * it has more information (distinguishes functions/classes/constructors etc.) * it is much simpler and probably faster, because it doesn't go via hiedb, it reads .hie files directly. * it is probably more correct, I fixed a lot of things. The schema is carefully designed so that a Name uniquely identifies an entity and corresponds fairly closely to GHC's Name, including OccName. The main difference is we don't store Uniques, instead we distinguish local Names by including their ByteSpan. There are a couple of snapshot tests, one for the plain indexer and one for the codemarkup layer, and a Glass regression test. Not done yet: * we can extract types from the .hie file too, and provide type hovers in Glass. That wouldn't be too hard. * extracting more structure so that we can reconstruct data/class decls should be possible but it's not straightforward using .hie. I'm still thinking about how best to do that. X-link: facebookincubator/Glean#511 Reviewed By: rubmary Differential Revision: D74400980 Pulled By: jjuliamolin fbshipit-source-id: 6cb183b96ef1c7030c8b7278434f84a4d72ceb28
Summary: Redesigned the schema and rewrote the indexer. Compared with the previous indexer: * this captures a lot more xrefs (e.g. local variables) * it has more information (distinguishes functions/classes/constructors etc.) * it is much simpler and probably faster, because it doesn't go via hiedb, it reads .hie files directly. * it is probably more correct, I fixed a lot of things. The schema is carefully designed so that a Name uniquely identifies an entity and corresponds fairly closely to GHC's Name, including OccName. The main difference is we don't store Uniques, instead we distinguish local Names by including their ByteSpan. There are a couple of snapshot tests, one for the plain indexer and one for the codemarkup layer, and a Glass regression test. Not done yet: * we can extract types from the .hie file too, and provide type hovers in Glass. That wouldn't be too hard. * extracting more structure so that we can reconstruct data/class decls should be possible but it's not straightforward using .hie. I'm still thinking about how best to do that. X-link: facebookincubator/Glean#511 Reviewed By: rubmary Differential Revision: D74400980 Pulled By: jjuliamolin fbshipit-source-id: 6cb183b96ef1c7030c8b7278434f84a4d72ceb28
Summary: Redesigned the schema and rewrote the indexer. Compared with the previous indexer: * this captures a lot more xrefs (e.g. local variables) * it has more information (distinguishes functions/classes/constructors etc.) * it is much simpler and probably faster, because it doesn't go via hiedb, it reads .hie files directly. * it is probably more correct, I fixed a lot of things. The schema is carefully designed so that a Name uniquely identifies an entity and corresponds fairly closely to GHC's Name, including OccName. The main difference is we don't store Uniques, instead we distinguish local Names by including their ByteSpan. There are a couple of snapshot tests, one for the plain indexer and one for the codemarkup layer, and a Glass regression test. Not done yet: * we can extract types from the .hie file too, and provide type hovers in Glass. That wouldn't be too hard. * extracting more structure so that we can reconstruct data/class decls should be possible but it's not straightforward using .hie. I'm still thinking about how best to do that. X-link: facebookincubator/Glean#511 Reviewed By: rubmary Differential Revision: D74400980 Pulled By: jjuliamolin fbshipit-source-id: 6cb183b96ef1c7030c8b7278434f84a4d72ceb28
Summary: Redesigned the schema and rewrote the indexer. Compared with the previous indexer: * this captures a lot more xrefs (e.g. local variables) * it has more information (distinguishes functions/classes/constructors etc.) * it is much simpler and probably faster, because it doesn't go via hiedb, it reads .hie files directly. * it is probably more correct, I fixed a lot of things. The schema is carefully designed so that a Name uniquely identifies an entity and corresponds fairly closely to GHC's Name, including OccName. The main difference is we don't store Uniques, instead we distinguish local Names by including their ByteSpan. There are a couple of snapshot tests, one for the plain indexer and one for the codemarkup layer, and a Glass regression test. Not done yet: * we can extract types from the .hie file too, and provide type hovers in Glass. That wouldn't be too hard. * extracting more structure so that we can reconstruct data/class decls should be possible but it's not straightforward using .hie. I'm still thinking about how best to do that. X-link: facebookincubator/Glean#511 Reviewed By: rubmary Differential Revision: D74400980 Pulled By: jjuliamolin fbshipit-source-id: 6cb183b96ef1c7030c8b7278434f84a4d72ceb28
|
Sorry broke the open source regression tests, had to split them into fb/oss.. maybe you can re-generate them @simonmar, or anyone else. I just don't have the access to the actual open source checkout yet so can't generate with the same result |
|
@jjuliamolin thanks for landing this! I fixed up the tests in this PR: #530 and also rebased the rest of the stack. I'm curious how the output differs when you run the tests internally, maybe that's something we can fix? |
|
@simonmar we'll pass the hie files to the binary (not using the --with-ghc option), so one difference that I didn't really managed to get around was the filepath. Also "unit" is different, seems to be based on the build targets, but haven't really looked into this one |
|
from hsDeclarationLocation.out ... |
|
@jjuliamolin yeah I see. OK having separate output for the internal & OSS tests is probably the right thing to do then. Great that you managed to get the tests working internally. |
Summary: It's useful to be able to know whether a ref is in an import or export, e.g. for dead code detection, so let's tag refs with an enum to say what kind of ref it is. I changed field names so that the schema change shouldn't trigger a validation failure (I hope). Note: stacked on #511 Pull Request resolved: #518 Test Plan: Imported from GitHub, without a `Test Plan:` line. Rollback Plan: Reviewed By: donsbot Differential Revision: D75066884 Pulled By: bochko fbshipit-source-id: b58f19b3bc9d4261b38640e30833916b654adc14
Redesigned the schema and rewrote the indexer. Compared with the previous indexer:
The schema is carefully designed so that a Name uniquely identifies an entity and corresponds fairly closely to GHC's Name, including OccName. The main difference is we don't store Uniques, instead we distinguish local Names by including their ByteSpan.
There are a couple of snapshot tests, one for the plain indexer and one for the codemarkup layer, and a Glass regression test.
Not done yet:
we can extract types from the .hie file too, and provide type hovers in Glass. That wouldn't be too hard.
extracting more structure so that we can reconstruct data/class decls should be possible but it's not straightforward using .hie. I'm still thinking about how best to do that.