From 4fe755854f8771c0d27d5deebc1e1c5c4f5fe787 Mon Sep 17 00:00:00 2001 From: Seth Hillbrand Date: Sun, 26 Nov 2023 16:46:51 -0800 Subject: [PATCH] Remove GCC extension syntax --- pcbnew/plugins/ipc2581/ipc2581_plugin.cpp | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/pcbnew/plugins/ipc2581/ipc2581_plugin.cpp b/pcbnew/plugins/ipc2581/ipc2581_plugin.cpp index a0b8a44dca..f39c4a1aea 100644 --- a/pcbnew/plugins/ipc2581/ipc2581_plugin.cpp +++ b/pcbnew/plugins/ipc2581/ipc2581_plugin.cpp @@ -1236,14 +1236,6 @@ void IPC2581_PLUGIN::addLayerAttributes( wxXmlNode* aNode, PCB_LAYER_ID aLayer ) { switch( aLayer ) { - case F_Cu ... B_Cu: - addAttribute( aNode, "layerFunction", "CONDUCTOR" ); - addAttribute( aNode, "polarity", "POSITIVE" ); - addAttribute( aNode, "side", - aLayer == F_Cu ? "TOP" - : aLayer == B_Cu ? "BOTTOM" - : "INTERNAL" ); - break; case F_Adhes: case B_Adhes: addAttribute( aNode, "layerFunction", "GLUE" ); @@ -1305,6 +1297,16 @@ void IPC2581_PLUGIN::addLayerAttributes( wxXmlNode* aNode, PCB_LAYER_ID aLayer ) break; default: + if( IsCopperLayer( aLayer ) ) + { + addAttribute( aNode, "layerFunction", "CONDUCTOR" ); + addAttribute( aNode, "polarity", "POSITIVE" ); + addAttribute( aNode, "side", + aLayer == F_Cu ? "TOP" + : aLayer == B_Cu ? "BOTTOM" + : "INTERNAL" ); + } + break; // Do not handle other layers } }