From 4acb97e02e6fc862ceb7ffff2a393a5d7be8fc44 Mon Sep 17 00:00:00 2001 From: Dick Hollenbeck Date: Tue, 27 Nov 2012 13:57:38 -0600 Subject: [PATCH] reverse throw() clauses to quiet SWIG errors --- pcbnew/kicad_plugin.cpp | 2 +- pcbnew/kicad_plugin.h | 2 +- pcbnew/pcb_plot_params.cpp | 4 ++-- pcbnew/pcb_plot_params.h | 7 +++++-- 4 files changed, 9 insertions(+), 6 deletions(-) diff --git a/pcbnew/kicad_plugin.cpp b/pcbnew/kicad_plugin.cpp index 60cdc1a989..36859deb74 100644 --- a/pcbnew/kicad_plugin.cpp +++ b/pcbnew/kicad_plugin.cpp @@ -309,7 +309,7 @@ void PCB_IO::Save( const wxString& aFileName, BOARD* aBoard, PROPERTIES* aProper } -BOARD_ITEM* PCB_IO::Parse( const wxString& aClipboardSourceInput ) throw( IO_ERROR, PARSE_ERROR ) +BOARD_ITEM* PCB_IO::Parse( const wxString& aClipboardSourceInput ) throw( PARSE_ERROR, IO_ERROR ) { std::string input = TO_UTF8( aClipboardSourceInput ); diff --git a/pcbnew/kicad_plugin.h b/pcbnew/kicad_plugin.h index cb6a387ae6..9b94bd9975 100644 --- a/pcbnew/kicad_plugin.h +++ b/pcbnew/kicad_plugin.h @@ -129,7 +129,7 @@ public: void SetOutputFormatter( OUTPUTFORMATTER* aFormatter ) { m_out = aFormatter; } BOARD_ITEM* Parse( const wxString& aClipboardSourceInput ) - throw( IO_ERROR, PARSE_ERROR ); + throw( PARSE_ERROR, IO_ERROR ); protected: diff --git a/pcbnew/pcb_plot_params.cpp b/pcbnew/pcb_plot_params.cpp index 58d087cd97..5d0fd927dc 100644 --- a/pcbnew/pcb_plot_params.cpp +++ b/pcbnew/pcb_plot_params.cpp @@ -186,7 +186,7 @@ void PCB_PLOT_PARAMS::Format( OUTPUTFORMATTER* aFormatter, void PCB_PLOT_PARAMS::Parse( PCB_PLOT_PARAMS_PARSER* aParser ) - throw( IO_ERROR, PARSE_ERROR ) + throw( PARSE_ERROR, IO_ERROR ) { aParser->Parse( this ); } @@ -310,7 +310,7 @@ PCB_PLOT_PARAMS_PARSER::PCB_PLOT_PARAMS_PARSER( char* aLine, const wxString& aSo void PCB_PLOT_PARAMS_PARSER::Parse( PCB_PLOT_PARAMS* aPcbPlotParams ) - throw( IO_ERROR, PARSE_ERROR ) + throw( PARSE_ERROR, IO_ERROR ) { T token; while( ( token = NextTok() ) != T_RIGHT ) diff --git a/pcbnew/pcb_plot_params.h b/pcbnew/pcb_plot_params.h index 8a72c5cbf9..bc316d4e59 100644 --- a/pcbnew/pcb_plot_params.h +++ b/pcbnew/pcb_plot_params.h @@ -41,8 +41,10 @@ class PCB_PLOT_PARAMS_PARSER : public PCB_PLOT_PARAMS_LEXER public: PCB_PLOT_PARAMS_PARSER( LINE_READER* aReader ); PCB_PLOT_PARAMS_PARSER( char* aLine, const wxString& aSource ); + LINE_READER* GetReader() { return reader; }; - void Parse( PCB_PLOT_PARAMS* aPcbPlotParams ) throw( IO_ERROR, PARSE_ERROR ); + + void Parse( PCB_PLOT_PARAMS* aPcbPlotParams ) throw( PARSE_ERROR, IO_ERROR ); bool ParseBool(); /** @@ -55,6 +57,7 @@ public: int ParseInt( int aMin, int aMax ); }; + /** * Class PCB_PLOT_PARAMS * handles plot parameters and options when plotting/printing a board. @@ -180,7 +183,7 @@ public: void Format( OUTPUTFORMATTER* aFormatter, int aNestLevel, int aControl=0 ) const throw( IO_ERROR ); - void Parse( PCB_PLOT_PARAMS_PARSER* aParser ) throw( IO_ERROR, PARSE_ERROR ); + void Parse( PCB_PLOT_PARAMS_PARSER* aParser ) throw( PARSE_ERROR, IO_ERROR ); bool operator==( const PCB_PLOT_PARAMS &aPcbPlotParams ) const; bool operator!=( const PCB_PLOT_PARAMS &aPcbPlotParams ) const;