Open
Description
Sublime Text Version
3.2.1, Build 3207
Rust Enhanced Version
2.20.0
Operating system
OS Name Microsoft Windows 10 Home
Version 10.0.18362 Build 18362
Expected behavior
The "_default" key for customizing the project target should pass it's value to cargo correctly, just like the specific file keys do.
Actual behavior
The target detector class appears to not call split on default values the way it does for specific matching key value pairs. The debug log produces this
+0.081 Running: cargo check - - l i b --message-format=json --profile=test
Steps to reproduce
- Configure a rust project
- Customize the target with a projects block in the RustEnhanced sublime settings with a "_default" key and no applicable other keys.
- Save a file in the rust project.
cargo check
will fail and the debug log will contain something similar to the message above. Using specific settings works fine. _default can use an array of strings instead to behave correctly. The settings should probably work one way or the other.
The offending line appears to be target_detect.py 82 _default seems to expect you to manually specify an array of arguments instead of a string, while specific keys (e.g. "lib.rs") only work with a string with spaces between arguments, which are split into an array of strings in the target detector class.