Sarrus1 / sourcepawn-studio

VSCode extension for SourcePawn scripting
https://sarrus1.github.io/sourcepawn-studio/
MIT License
140 stars 22 forks source link

Incorrect error message for struct array #346

Closed gandor233 closed 3 months ago

gandor233 commented 10 months ago

Basic informations

OS: [Windows] VSCode version: [v1.83.0] Extension version: [v6.1.0]

Code to reproduce the behaviour

enum struct TEST_STRUCT
{
    char str[256];
}
public void OnPluginStart()
{
    TEST_STRUCT sTestStructArray[1][1];
    Format(sTestStructArray[0][0].str, sizeof(sTestStructArray[][].str), "Why error?");
}

Error messages

(ERROR)

ScreenShot

Sarrus1 commented 3 months ago

This has been fixed in the grammar and merged in main. It is already fixed in the pre-release.