Make script source hashing faster Do not calcualte the hash for the same script multiple times. The hash is now stored in the text resource itself so we don't need an externall managed cache. The UriTextResource implementation has been thoroughly optimized for local file URIs. Previously reading those in was a major bottleneck due to copying every byte into 4(!) different buffers.
Adding the HashCode to the TextResource made me aware of the fact that the tooling API depended on these interfaces, although it should never be reading scripts. It turns out that the script was attached to the BuildLayout, where it didn't really belong. It is now only created once the build is running and we are actually trying to load the settings file. There were a few changes to types marked with @UsedByScanPlugin. These were all checked against the scan plugin code base to ensure they are safe. The reported data is now more accurate as it returns a `null` value for a non-existing settings file instead of reporting a dummy path.