EngineHub / EngineHub/CommandHelper

Static analysis exception "Procedure cannot be resolved" when procedure exists

Ouverte
#1,239 3 commentaires 0 réactions 0 personnes assignées Voir sur GitHub
Langage dominant
Java
Étoiles
128
Forks
70
Métriques de merge des PR
Aucune PR mergée en 30 j

Description

Static analysis will throw exception with message "Procedure cannot be resolved" for all user procedures in this case:
```
# main.ms
proc _path() {
return('test-2.ms')
}

proc _test() {
console('test')
}

include('test-1.ms')
```
```
# test-1.ms
include(_path())
```
```
# test-2.ms
_test()
```
```
ms.lang.IncludeException: There was a compile error when trying to include the script at C:\Users\A-y57\Dev\minecraft\plugins\CommandHelper\test-2.ms
Procedure cannot be resolved: _test :: test-2.ms:1
at <>:C:\Users\A-y57\Dev\minecraft\plugins\CommandHelper\test-1.ms:1.9
at <>:C:\Users\A-y57\Dev\minecraft\plugins\CommandHelper\main.ms:9.2
```
If replace _path with 'test-2.ms' - everything works
If disable static analysis, everything works

Guide de contribution

Ouvrir le guide de contribution

Évaluation

Cette issue n'a pas encore été évaluée.

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.