Index: trunk/src/flag.c =================================================================== --- trunk/src/flag.c (revision 5252) +++ trunk/src/flag.c (revision 5253) @@ -38,24 +38,6 @@ return rv; } -/* This converts old flag bits (from saved PCB files) to new format. */ -pcb_flag_t pcb_flag_old(unsigned int flags) -{ - pcb_flag_t rv; - int i, f; - memset(&rv, 0, sizeof(rv)); - /* If we move flag bits around, this is where we map old bits to them. */ - rv.f = flags & 0xffff; - f = 0x10000; - for (i = 0; i < 8; i++) { - /* use the closest thing to the old thermal style */ - if (flags & f) - rv.t[i / 2] |= (1 << (4 * (i % 2))); - f <<= 1; - } - return rv; -} - pcb_flag_t pcb_flag_add(pcb_flag_t flag, unsigned int flags) { flag.f |= flags; Index: trunk/src_plugins/io_pcb/parse_y.y =================================================================== --- trunk/src_plugins/io_pcb/parse_y.y (revision 5252) +++ trunk/src_plugins/io_pcb/parse_y.y (revision 5253) @@ -94,6 +94,7 @@ static int integer_value (PLMeasure m); static pcb_coord_t old_units (PLMeasure m); static pcb_coord_t new_units (PLMeasure m); +static pcb_flag_t pcb_flag_old(unsigned int flags); #define YYDEBUG 1 #define YYERROR_VERBOSE 1 @@ -2072,3 +2073,21 @@ /* if there's no unit m.dval already contains the converted value */ return pcb_round (m.dval); } + +/* This converts old flag bits (from saved PCB files) to new format. */ +static pcb_flag_t pcb_flag_old(unsigned int flags) +{ + pcb_flag_t rv; + int i, f; + memset(&rv, 0, sizeof(rv)); + /* If we move flag bits around, this is where we map old bits to them. */ + rv.f = flags & 0xffff; + f = 0x10000; + for (i = 0; i < 8; i++) { + /* use the closest thing to the old thermal style */ + if (flags & f) + rv.t[i / 2] |= (1 << (4 * (i % 2))); + f <<= 1; + } + return rv; +}