Coder deleting variable definitions
古いコメントを表示
Why oh why does coder feel the need to delete my variable definitions from time to time? It is unbelievably frustrating having to redefine 200+ variables.
13 件のコメント
Walter Roberson
2012 年 6 月 13 日
Adam, as a work-around, could you perhaps put the variable definitions into a different file and #include that file ?
Adam Kaas
2012 年 6 月 13 日
Walter Roberson
2012 年 6 月 13 日
Write the definitions into YourFileName.h. Then at the point in the C code that you need the variables defined, you would put the line
#include "YourFileName.h"
This has the effect of inserting everything from YourFileName.h as-if it had all been typed in at that point in the source.
Walter Roberson
2012 年 6 月 13 日
Note: the double-quote marks are important for the syntax.
Adam Kaas
2012 年 6 月 13 日
Kaustubha Govind
2012 年 6 月 13 日
Adam: Are these variables not being used in the rest of your code? I would expect the variable definitions to be removed only as an optimization.
Adam Kaas
2012 年 6 月 13 日
Walter Roberson
2012 年 6 月 13 日
This would not be an entry-point file.
Kaustubha Govind
2012 年 6 月 14 日
Are the variable zeta and w being used in some part of S1.m?
Adam Kaas
2012 年 6 月 14 日
Adam Kaas
2012 年 6 月 14 日
Kaustubha Govind
2012 年 6 月 14 日
Adam: I think I'm a little confused about your workflow. Perhaps you should consider sending your files and reproduction steps to MathWorks Tech Support and verify if this is expected behavior or a bug?
Adam Kaas
2012 年 6 月 14 日
採用された回答
その他の回答 (1 件)
Rich McKeever
2012 年 6 月 26 日
1 投票
Adam,
We saw your post about the issue here and fixed the bug yesterday. A patch is available here, but I also second Fred's suggestion of using other methods for defining large numbers of inputs.
Thanks,
Rich
カテゴリ
ヘルプ センター および File Exchange で DSP Algorithm Acceleration についてさらに検索
製品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!