Einzelnen Beitrag anzeigen

Benutzerbild von DP News-Robot
DP News-Robot

Registriert seit: 4. Jun 2010
14.983 Beiträge
 
#1

New Delphi 10.3 Warning "Unknown Custom Attribute"

  Alt 30. Nov 2018, 16:30
Up to Delphi 102, if you used a custom attribute that was not known to the compiler (because you typed*it incorrectly*or a unit was missing in the uses statement), you'd receive the warning:

Warning: W1025 Unsupported language feature: 'custom attribute' This message was misleading, because the feature has been in the language for quite some time, it was just using an undefined symbol in it. There is a large list of reports on this issue, including*https://quality.embarcadero.com/browse/RSP-20384.*

Starting with 10.3, the same code will trigger a new specific warning:

Warning: W1074 Unknown custom attribute This conveys a more specific information. It also makes it is easier to turn this warning into an error -- which would often make sense, by using the directive:

{$WARN UNKNOWN_CUSTOM_ATTRIBUTE ERROR} In the past you could achieve the same by turning the unsupported language feature*warnings*into errors, but that could have included also other unwanted scenarios.



Weiterlesen...
  Mit Zitat antworten Zitat