Menu

#195 dthelp: K&R-era strstr() caused fproto error

open
nobody
None
2026-05-18
2026-05-18
Trung Le
No

The dthelp pass2/htag2 helper redeclares strstr() with a K&R-era
prototype. On modern glibc, <string.h> declares strstr() through a
_Generic macro for type-safe const handling, and the redeclaration in
fproto.h triggers:

 fproto.h:34:7: error: expected identifier or '(' before '_Generic'

The standard declaration from <string.h> (already pulled in via
userinc.h -> stdio.h -> features.h) is correct and sufficient.

1 Attachments

Discussion


Log in to post a comment.

MongoDB Logo MongoDB