Open dzzzb opened 3 years ago
@dtkb is this still a problem?
Yes, the compiler still doesn't warn that unsupported Rec.
prefixes will either cause a runtime error or simply crash the client. Same example, redone:
I would expect that
Rec.
prefixes and, if unsupported, make that a compile-time error or at least a warning, so we don't waste time publishing that code to site only to have the client crash.Name: AL Language
Id: ms-dynamics-smb.al
Description: AL development tools for Dynamics 365 Business Central
Version: 7.1.453917
Publisher: Microsoft
VS Marketplace Link: https://marketplace.visualstudio.com/items?itemName=ms-dynamics-smb.al
Describe the bug If a page has added explicit
Rec.
qualifiers to fields or properties, these are not supported in runtimes before 6, but there are no warnings at compile-time, so if we backport an extension or just includeRec.
out of habit to an older runtime, we find only later that it doesn't work, and have to waste our time and disturb users by republishing withoutRec.
Worse, not all unsupported cases are even reported at runtime, at least not until you go looking elsewhere... for example, I just found that
Rec.
in aHideValue
expression just causes the client to lock up and spew a bunch of errors in an infinite loop!To Reproduce Here is the page after I mostly fixed it but forgot the
Rec.
in theHideValue
expression, which caused the inability to open the page as it silently spun an infinite loop as per above.Expected behavior If compiling against a runtime that doesn't support
Rec.
anywhere, stop the developer with an error, rather than deferring that until runtime and wasting everyone's time. Please?5. Versions: