Code analyzer bar not indicating syntax errors.
clear on line 3 is mispelled but there is a green box in the code analyzer bar???
An error results in the command window when this code is run.
The code analyzer is enabled in Preferences.
I believe this has recognized this type of systax error in earlier editions.
Jack Koscinski

 採用された回答

Steven Lord
Steven Lord 2020 年 9 月 14 日

0 投票

There are some problems that Code Analyzer's static analysis can detect, but a misspelled function name is not always something it can detect. [If you misspell it badly enough, like misspelling the x2fx function from Statistics and Machine Learning Toolbox as 2fx which is not a valid function name, Code Analyzer can detect it.] You intended that line to call the clear function, but how can you know just by looking at that file (static analysis) that there's no function named clea that is being called?

その他の回答 (0 件)

カテゴリ

ヘルプ センター および File ExchangeProgramming についてさらに検索

製品

リリース

R2020a

タグ

質問済み:

2020 年 9 月 14 日

回答済み:

2020 年 9 月 14 日

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by