[Bug 279403] typedef redeclaration in base include becoming an issue for DTrace
Date: Thu, 30 May 2024 19:56:50 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=279403 Mark Johnston <markj@FreeBSD.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |markj@FreeBSD.org Status|New |Open --- Comment #1 from Mark Johnston <markj@FreeBSD.org> --- Has this example ever worked on FreeBSD? The problem isn't with duplicate typedefs; those are errors in C as well. In dt_parser.c we have: 1451 /* 1452 * If we are nested inside of a C include file, add the declaration to 1453 * the C definition module; otherwise use the D definition module. 1454 */ 1455 if (yypcb->pcb_idepth != 0) 1456 dmp = dtp->dt_cdefs; 1457 else 1458 dmp = dtp->dt_ddefs; When we hit the error, we're actually using ddefs instead of cdefs, which is incorrect according to the comment. How is pcb_idepth set? It's adjusted when we see line control directives emitted by the processor, but it looks like our version of the D lexer isn't handling this properly somehow. -- You are receiving this mail because: You are the assignee for the bug.