Added a crawler to extract NtStatus definitions from MSDN #9
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hi,
I wrote a simple crawler based on github.com/PuerkitoBio/goquery to extract the NtStatus codes from https://msdn.microsoft.com/en-us/library/cc704588.aspx. In ntstatus.go, a go:generate now calls statuscrawler which generates ntstatus_generated.go.
ntstatus_generated.go contains the consts as well as the String() method for NtStatus to derive the STATUS_* name for a given NtStatus (via a map[NtStatus]string{}. The stringer-tool, for some reason, did not provide a properly generated go-file).
It adds a timestamp to the generated file, based on the
<meta name="ms.sitever" content="...">
-tag in the HTML-file.Hope this is what you had in mind with your "FIXME"-comment in ntstatus.go.
Cheers,
Özgür