From: Uwe Hermann Date: Sun, 21 Oct 2012 14:03:08 +0000 (+0200) Subject: Fix #include guards. X-Git-Url: http://git.code-monkey.de/?p=pulseview.git;a=commitdiff_plain;h=640d091b45b196cc586fbc6a7bec71c5c7d75544 Fix #include guards. - Add missing #include guards. - Fix incorrect #endif comments for some #include guards. - Use consistent naming for them, as per HACKING. --- diff --git a/extdef.h b/extdef.h index c2a0f16..8af615c 100644 --- a/extdef.h +++ b/extdef.h @@ -18,12 +18,12 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ -#ifndef _EXTDEF_H -#define _EXTDEF_H +#ifndef PULSEVIEW_EXTDEF_H +#define PULSEVIEW_EXTDEF_H #define countof(x) (sizeof(x)/sizeof(x[0])) #define begin_element(x) (&x[0]) #define end_element(x) (&x[countof(x)]) -#endif /* _EXTDEF_H */ +#endif // PULSEVIEW_EXTDEF_H diff --git a/pv/about.h b/pv/about.h index 31392b2..5b845cb 100644 --- a/pv/about.h +++ b/pv/about.h @@ -18,8 +18,8 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ -#ifndef ABOUT_H -#define ABOUT_H +#ifndef PULSEVIEW_PV_ABOUT_H +#define PULSEVIEW_PV_ABOUT_H #include @@ -48,4 +48,4 @@ private: } // namespace pv -#endif // ABOUT_H +#endif // PULSEVIEW_PV_ABOUT_H diff --git a/pv/datasnapshot.h b/pv/datasnapshot.h index 221ebcd..9c0866d 100644 --- a/pv/datasnapshot.h +++ b/pv/datasnapshot.h @@ -18,6 +18,9 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ +#ifndef PULSEVIEW_PV_DATASNAPSHOT_H +#define PULSEVIEW_PV_DATASNAPSHOT_H + extern "C" { #include } @@ -43,3 +46,5 @@ protected: }; } // namespace pv + +#endif // PULSEVIEW_PV_DATASNAPSHOT_H diff --git a/pv/logicdata.h b/pv/logicdata.h index b21d50a..11e5f9a 100644 --- a/pv/logicdata.h +++ b/pv/logicdata.h @@ -18,6 +18,9 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ +#ifndef PULSEVIEW_PV_LOGICDATA_H +#define PULSEVIEW_PV_LOGICDATA_H + #include "signaldata.h" #include @@ -51,3 +54,5 @@ private: }; } // namespace pv + +#endif // PULSEVIEW_PV_LOGICDATA_H diff --git a/pv/logicdatasnapshot.h b/pv/logicdatasnapshot.h index 8e494be..2a18835 100644 --- a/pv/logicdatasnapshot.h +++ b/pv/logicdatasnapshot.h @@ -18,6 +18,9 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ +#ifndef PULSEVIEW_PV_LOGICDATASNAPSHOT_H +#define PULSEVIEW_PV_LOGICDATASNAPSHOT_H + #include "datasnapshot.h" #include @@ -99,3 +102,5 @@ private: }; } // namespace pv + +#endif // PULSEVIEW_PV_LOGICDATASNAPSHOT_H diff --git a/pv/logicsignal.h b/pv/logicsignal.h index 42acee8..54145a8 100644 --- a/pv/logicsignal.h +++ b/pv/logicsignal.h @@ -18,6 +18,9 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ +#ifndef PULSEVIEW_PV_LOGICSIGNAL_H +#define PULSEVIEW_PV_LOGICSIGNAL_H + #include "signal.h" #include @@ -77,3 +80,5 @@ private: }; } // namespace pv + +#endif // PULSEVIEW_PV_LOGICSIGNAL_H diff --git a/pv/mainwindow.h b/pv/mainwindow.h index 88cbd6f..8b813af 100644 --- a/pv/mainwindow.h +++ b/pv/mainwindow.h @@ -18,8 +18,8 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ -#ifndef MAINWINDOW_H -#define MAINWINDOW_H +#ifndef PULSEVIEW_PV_MAINWINDOW_H +#define PULSEVIEW_PV_MAINWINDOW_H #include @@ -88,4 +88,4 @@ private slots: } // namespace pv -#endif // MAINWINDOW_H +#endif // PULSEVIEW_PV_MAINWINDOW_H diff --git a/pv/samplingbar.h b/pv/samplingbar.h index 170379e..e6204df 100644 --- a/pv/samplingbar.h +++ b/pv/samplingbar.h @@ -18,8 +18,8 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ -#ifndef SAMPLINGBAR_H -#define SAMPLINGBAR_H +#ifndef PULSEVIEW_PV_SAMPLINGBAR_H +#define PULSEVIEW_PV_SAMPLINGBAR_H #include @@ -71,4 +71,4 @@ private: } // namespace pv -#endif // SAMPLINGBAR_H +#endif // PULSEVIEW_PV_SAMPLINGBAR_H diff --git a/pv/signal.h b/pv/signal.h index 18ff4b4..789b436 100644 --- a/pv/signal.h +++ b/pv/signal.h @@ -18,6 +18,9 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ +#ifndef PULSEVIEW_PV_SIGNAL_H +#define PULSEVIEW_PV_SIGNAL_H + #include #include @@ -111,3 +114,5 @@ protected: }; } // namespace pv + +#endif // PULSEVIEW_PV_SIGNAL_H diff --git a/pv/signaldata.h b/pv/signaldata.h index 57cd543..94268ae 100644 --- a/pv/signaldata.h +++ b/pv/signaldata.h @@ -18,6 +18,9 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ +#ifndef PULSEVIEW_PV_SIGNALDATA_H +#define PULSEVIEW_PV_SIGNALDATA_H + #include namespace pv { @@ -37,3 +40,5 @@ protected: }; } // namespace pv + +#endif // PULSEVIEW_PV_SIGNALDATA_H diff --git a/pv/sigsession.h b/pv/sigsession.h index 40fce89..b6e5a56 100644 --- a/pv/sigsession.h +++ b/pv/sigsession.h @@ -18,8 +18,8 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ -#ifndef SIGSESSION_H -#define SIGSESSION_H +#ifndef PULSEVIEW_PV_SIGSESSION_H +#define PULSEVIEW_PV_SIGSESSION_H #include @@ -81,4 +81,4 @@ private: } // namespace pv -#endif // SIGSESSION_H +#endif // PULSEVIEW_PV_SIGSESSION_H diff --git a/pv/view/header.h b/pv/view/header.h index a92d117..6b97c4a 100644 --- a/pv/view/header.h +++ b/pv/view/header.h @@ -18,8 +18,8 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ -#ifndef PV_VIEW_HEADER_H -#define PV_VIEW_HEADER_H +#ifndef PULSEVIEW_PV_VIEW_HEADER_H +#define PULSEVIEW_PV_VIEW_HEADER_H #include @@ -65,4 +65,4 @@ private: } // namespace view } // namespace pv -#endif // PV_VIEW_HEADER_H +#endif // PULSEVIEW_PV_VIEW_HEADER_H diff --git a/pv/view/ruler.h b/pv/view/ruler.h index 18b565e..f855185 100644 --- a/pv/view/ruler.h +++ b/pv/view/ruler.h @@ -18,8 +18,8 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ -#ifndef PV_VIEW_RULER_H -#define PV_VIEW_RULER_H +#ifndef PULSEVIEW_PV_VIEW_RULER_H +#define PULSEVIEW_PV_VIEW_RULER_H #include @@ -52,4 +52,4 @@ private: } // namespace view } // namespace pv -#endif // PV_VIEW_HEADER_H +#endif // PULSEVIEW_PV_VIEW_RULER_H diff --git a/pv/view/view.h b/pv/view/view.h index d2abbf0..c87be36 100644 --- a/pv/view/view.h +++ b/pv/view/view.h @@ -18,8 +18,8 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ -#ifndef PV_VIEW_VIEW_H -#define PV_VIEW_VIEW_H +#ifndef PULSEVIEW_PV_VIEW_VIEW_H +#define PULSEVIEW_PV_VIEW_VIEW_H #include @@ -98,4 +98,4 @@ private: } // namespace view } // namespace pv -#endif // PV_VIEW_VIEW_H +#endif // PULSEVIEW_PV_VIEW_VIEW_H diff --git a/pv/view/viewport.h b/pv/view/viewport.h index e2517fa..a33d404 100644 --- a/pv/view/viewport.h +++ b/pv/view/viewport.h @@ -18,8 +18,8 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ -#ifndef PV_VIEW_VIEWPORT_H -#define PV_VIEW_VIEWPORT_H +#ifndef PULSEVIEW_PV_VIEW_VIEWPORT_H +#define PULSEVIEW_PV_VIEW_VIEWPORT_H #include #include @@ -61,4 +61,4 @@ private: } // namespace view } // namespace pv -#endif // PV_VIEW_VIEWPORT_H +#endif // PULSEVIEW_PV_VIEW_VIEWPORT_H