Apply implicit search exclude filters when seaching for Erlang source files in the project
Apply some extra exclude filters when search for Erlang source files if there is no corresponding configuration available.
Exclude filters acome from three sources: files.exclude, search.exclude and files.watcherExclude. It's the project responsibility to configure these settings properly. From other hand, the extension automatically handles rebar3 build directory, as the de facto build tool for Erlang application, therefore it's not necessary to configure the above settings for rebar3.
Case study:
Some project uses other build tools, like Bazel that creates some sym-links in the project root directory pointing to some directory in the build cache (located somewhere else and contains a whole bunch of everything). Also, it links all the dependencies next to the test (and maybe all) targets inside the build cache. Therefore dependencies may be found in the build cache multiple times and all of them are located (through sym-links) in the project directory. Such a dependency for Erlang rules can be Erlang/OTP that might contain the source code too. It means, all Erlang files of OTP (thousands) will be found and parsed by the extension multiple times, as all the occurrences are located under some different paths (via sym-links). At the end of the day, it can lead to hundred of thousands parsed files and huge memory consumption. Of course, if the above three settings are configured properly, this extension can ignore all of these unwanted files from Bazel cache and parse the real source files only.
This commit aims to create a safety for projects that didn't configure exclude filters, similar to handling of rebar3 build directory. If at least one corresponding exclude filter is added to the settings then we trust the settings and don't apply the extra exclude filter.
This is an addition to pull request #265.