- Configure exclusion rules: Some code inspection tools provide the ability to configure exclusion rules based on specific criteria. You can create exclusion rules for the headers and sources that are part of your legacy code, so that the warnings related to these files are suppressed.
- Create dummy headers: If the missing headers are not critical for the analysis, you can create dummy header files with empty content and include them in your configuration. This way, the Code Inspector will find the headers it expects, and the warnings will be avoided.
- Refactor the code: If possible, consider refactoring your code to reduce the coupling between the generated code and the legacy hand code. By decoupling the dependencies, you can make the code more modular and easier to analyse with tools like Code Inspector.
Code Inspector with Legacy Code
1 visualización (últimos 30 días)
Mostrar comentarios más antiguos
Hi,
I am trying to use Code Inspector in a project where the generated code has to link with a large amount of legacy hand code. I have to use certain headers from the hand code to link to the generated code, and I have added #include statements for these headers in my configuration for custom code. When I run code inspector, I get a series of warnings about not having my custom code headers and sources set to "" or unspecified.
I know why I am getting the warning, and there is no way to avoid it in my program. Short of just accepting these warnings, how do people normally handle this?
Thanks!
0 comentarios
Respuestas (1)
Riya
el 19 de Nov. de 2023
Hello John Fiaschetti,
As per my understanding, while running code inspector, you are getting a series of warnings about not having custom code.
Please note that when dealing with legacy code and Code Inspector, there are a few approaches you can consider to handle the warnings about missing custom code headers and sources. Here are some common solutions:
Remember, the best approach may vary depending on the specifics of your project and the capabilities of the Code Inspector tool you are using.
I hope it helps!
Regards,
Riya Arora
0 comentarios
Ver también
Categorías
Más información sobre Deployment, Integration, and Supported Hardware en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!