[zscript] [clang] Build failures

Bugs that have been investigated and resolved somehow.

Moderator: GZDoom Developers

Forum rules
Please don't bump threads here if you have a problem - it will often be forgotten about if you do. Instead, make a new thread here.
Post Reply
kevans91
Posts: 72
Joined: Tue Sep 16, 2014 11:25 am

[zscript] [clang] Build failures

Post by kevans91 »

Hi,

Hitting the following build failure on Clang:
Spoiler: Excerpt from https://jenkins.kyle-evans.net/jenkins/job/ZDoom/45/consoleText
Seems to have started here: https://github.com/rheit/zdoom/commit/a ... ba0aae86a7
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49238
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: [zscript] [clang] Build failures

Post by Graf Zahl »

Urgh. This is one of the more annoying traits of Visual Studio that it silently converts any zero constant to a null pointer...
kevans91
Posts: 72
Joined: Tue Sep 16, 2014 11:25 am

Re: [zscript] [clang] Build failures

Post by kevans91 »

Eww, that's particularly ill-behaved. =( This is [fixed], by the way. =)
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49238
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: [zscript] [clang] Build failures

Post by Graf Zahl »

Actually, it's not. Assigning 0 to a pointer is perfectly legal in C++, NULL is nothing different. Actually it's Clang which is, strictly spoken, wrong here, it's understandable why but it's still adding semantics to something that cannot be made part of the standard.
kevans91
Posts: 72
Joined: Tue Sep 16, 2014 11:25 am

Re: [zscript] [clang] Build failures

Post by kevans91 »

Graf Zahl wrote:Actually, it's not. Assigning 0 to a pointer is perfectly legal in C++, NULL is nothing different. Actually it's Clang which is, strictly spoken, wrong here, it's understandable why but it's still adding semantics to something that cannot be made part of the standard.
Yeah, I suppose it just feels wrong to make the logical leap from false -> 0 -> pointer value. On the other hand, I also feel dirty about NULL = (void*)0, so fair enough. =)

This re-surfaced again, by the way, in https://github.com/rheit/zdoom/commit/3 ... 0bca7368e4
Spoiler: Excerpt from https://jenkins.kyle-evans.net/jenkins/job/ZDoom/lastBuild/consoleText
Post Reply

Return to “Closed Bugs [GZDoom]”