Hi,
is-there precaution (in X# compiler) to issue a warning that the variable will be USUAL when I write:
LOCAL cVariable := "something"
forgeting the 'AS TYPE' ?
regards
George
Compiler warning for missing type in declaration
Compiler warning for missing type in declaration
Hi George!
The current version of the C# compiler does not support USUALs anyway, so your sample is producing an error at this line with a message "Type expected". In future builds, there will be a compiler option with which you'll be able to specify that you want to use the core version of the compiler (so still an error reported in that kind of code), the VO/Vulcan compatibility one (so no error) etc. Even in the case of using the VO compatibility flavor, I think we can also add an optional (via a compiler switch) warning on defining vars without explicitly specifying their type.
Chris
The current version of the C# compiler does not support USUALs anyway, so your sample is producing an error at this line with a message "Type expected". In future builds, there will be a compiler option with which you'll be able to specify that you want to use the core version of the compiler (so still an error reported in that kind of code), the VO/Vulcan compatibility one (so no error) etc. Even in the case of using the VO compatibility flavor, I think we can also add an optional (via a compiler switch) warning on defining vars without explicitly specifying their type.
Chris
Chris Pyrgas
XSharp Development Team
chris(at)xsharp.eu
XSharp Development Team
chris(at)xsharp.eu
Compiler warning for missing type in declaration
> The current version of the C# compiler does ...
That should read "the X# compiler" of course!!
Chris
That should read "the X# compiler" of course!!
Chris
Chris Pyrgas
XSharp Development Team
chris(at)xsharp.eu
XSharp Development Team
chris(at)xsharp.eu
Compiler warning for missing type in declaration
Chris,
thank you for your answer.
I just tried the X# in both XIDE and VS2015.
No problem at all with the test App in XIDE (it's a mature product), but in VS2015 a simple WinForms app created using the template, do not run the debugger because the System.Drawing isn't automatically added to the references.
regards
George
thank you for your answer.
I just tried the X# in both XIDE and VS2015.
No problem at all with the test App in XIDE (it's a mature product), but in VS2015 a simple WinForms app created using the template, do not run the debugger because the System.Drawing isn't automatically added to the references.
regards
George
Compiler warning for missing type in declaration
Hi George,
Thanks for your report. I confirm that System.Drawing.dll is not automatically added as a reference, but even so, for some reason in my machine the WinForms app template builds and runs just fine here! Not sure why this is happening, will investigate it. I guess if you manually add the reference the sample works on your machine, too, is that right?
Chris
Thanks for your report. I confirm that System.Drawing.dll is not automatically added as a reference, but even so, for some reason in my machine the WinForms app template builds and runs just fine here! Not sure why this is happening, will investigate it. I guess if you manually add the reference the sample works on your machine, too, is that right?
Chris
Chris Pyrgas
XSharp Development Team
chris(at)xsharp.eu
XSharp Development Team
chris(at)xsharp.eu
Compiler warning for missing type in declaration
Chris,
>I guess if you manually add the reference the sample works on your machine, too, is that right?
True.
regards
George
>I guess if you manually add the reference the sample works on your machine, too, is that right?
True.
regards
George