mathworks / MATLAB-extension-for-vscode

This extension provides support for editing MATLAB® code in Visual Studio® Code and includes features such as syntax highlighting, code analysis, navigation support, and more.
https://marketplace.visualstudio.com/items?itemName=MathWorks.language-matlab
MIT License
244 stars 16 forks source link

Feature request: Variable substitution #141

Open stertingen opened 7 months ago

stertingen commented 7 months ago

Is your feature request related to a problem? Please describe. I would like to set up C/C++ IntelliSense with includes and defines for MEX files for the correct MATLAB installation. Maybe even the configured compiler for MEX (the one from mex -setup).

Describe the solution you'd like I would like to use something like ${command:matlab.getMatlabRoot} within settings.json and c_cpp_properties.json. See also: https://github.com/microsoft/vscode-cmake-tools/blob/main/docs/cmake-settings.md#variable-substitution

Describe alternatives you've considered Not really, maybe environment variables? The MATLAB extension could also provide a C/C++ configuration similar to CMake Tools, but i'm not sure how it does that. (https://code.visualstudio.com/docs/cpp/configure-intellisense)

Additional context Again, CMake Tools provides really convenient variable substitution features.