[Info-vax] [OT?] Should compiler warnings be treated as errors ?
hb
end.of at inter.net
Mon Sep 13 06:10:28 EDT 2021
On 9/12/21 3:08 PM, Simon Clubley wrote:
> On 2021-09-10, hb <end.of at inter.net> wrote:
>> On 9/10/21 7:41 PM, Simon Clubley wrote:
>>> On 2021-09-10, Craig A. Berry <craigberry at nospam.mac.com> wrote:
>>>> On 9/10/21 9:32 AM, hb wrote:
>>>>>
>>>>> Do you ask for a linker switch (or by default?) to disable image
>>>>> production in case of a warning?
>>>>
>>>> No. I didn't know there was such a switch.
>>>>
>>>
>>> I've just had a look in the online help and I can't find it either.
>>>
>>> It could be useful so I would be interested in knowing what that
>>> qualifier is. (I am assuming that it would cause LINK to exit with
>>> an error-level status that could be detected within a build procedure.)
>>>
>>
>> Maybe I didn't make it clear. It would have been better if I had asked,
>> do you want/need such a qualifier? If implemented, the DCL status code
>> will/should be an error code, something like ERRORISUE, "completed with
>> errors".
>
> I see. Yes, that would be something very useful to have, but it must
> _not_ complete, in the form of actually generating an executable (even
> with an error status), as that would defeat much of the benefit.
>
> The reason for that is that it would satisfy the current dependency for
> whatever make tool you are using, so make would move onto the next
> target instead of retrying the failed target when you ran make again.
>
> Simon.
>
As said before, if the linker encounters an error it will not generate
an image file. So *IF* this is implemented and a warning is promoted to
an error, you will not get an image file. As usual, the linker tries to
continue linking and producing a map file, if requested, to help
resolving the warning/error.
More information about the Info-vax
mailing list