Closed adriangaro closed 4 months ago
If a parameter is declared in the cwt config, ideally it should be considered used, if it has been intentionally declared there (even maybe if infering from the inline is impossible). It will help with cases where the logic might be too complex/niche and allow modders to overwrite those parameters and correct what cannot be inferred.
Use 1.3.3 or pre-released 1.3.4? The used or not inspection is implemented based on related indices. However in pre-released 1.3.4 parameter index is disabled due to IDE freezing problem. If you use 1.3.3, this shoulf be a index problem or inspection implementation problem.
It's not desired to be based on CWT configs, same for other things. You can instead "Suppress or disable related inspections"
1.3.4 is used here, same behaviour was prior in 1.3.3 i think. But can check
So it is, plz ignore it since 1.3.4 is not fully updated.
Ok will do, thanks for the note, atm disabled the inspection, so that is a temporary good solution. Should I keep this open till 1.3.4 is fully realeased?
Just let me check, update and then close this issue.
Parameters of inlines show as unused if they cannot be inferred correctly even if declared in cwt config.
Inline definition
Cwt parameter definitions
Usage
As it can be seen the
value
parameter is shown as unused, and when trying to autocomplete it, the IDE does not suggest it. Same withcode
This also might be tied to another bug i found that single counted strings are not accepted, while they do work for scripting purposes in general, the main use case is being able to pass double quoted strings as parameters since, escaping the quotes otherwise can cause issue downstream when the mod is loaded. Will create a separate bug for this too.