[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Toon-members] TooN TooN.h internal/dchecktest.hh
From: |
Tom Drummond |
Subject: |
[Toon-members] TooN TooN.h internal/dchecktest.hh |
Date: |
Thu, 02 Jul 2009 13:12:30 +0000 |
CVSROOT: /cvsroot/toon
Module name: TooN
Changes by: Tom Drummond <twd20> 09/07/02 13:12:30
Modified files:
. : TooN.h
Added files:
internal : dchecktest.hh
Log message:
added argument checking code to be used in generic static/dynamic code
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/TooN/internal/dchecktest.hh?cvsroot=toon&rev=1.1
http://cvs.savannah.gnu.org/viewcvs/TooN/TooN.h?cvsroot=toon&r1=1.47&r2=1.48
Patches:
Index: TooN.h
===================================================================
RCS file: /cvsroot/toon/TooN/TooN.h,v
retrieving revision 1.47
retrieving revision 1.48
diff -u -b -r1.47 -r1.48
--- TooN.h 24 Jun 2009 15:15:43 -0000 1.47
+++ TooN.h 2 Jul 2009 13:12:30 -0000 1.48
@@ -185,6 +185,7 @@
typedef double DefaultPrecision;
}
+#include <TooN/internal/dchecktest.hh>
#include <TooN/internal/allocator.hh>
#include <TooN/internal/size_mismatch.hh>
Index: internal/dchecktest.hh
===================================================================
RCS file: internal/dchecktest.hh
diff -N internal/dchecktest.hh
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ internal/dchecktest.hh 2 Jul 2009 13:12:30 -0000 1.1
@@ -0,0 +1,19 @@
+
+namespace TooN {
+
+struct Argument_Needed_For_Dynamic_Parameter{};
+
+namespace Internal {
+ template<int N>
+ struct DCheck {
+ static int val() {return N;}
+ };
+
+ template<>
+ struct DCheck<-1>{
+ static Argument_Needed_For_Dynamic_Parameter val(); // {return
ArgumentNeededForDynamicParameter();}
+ };
+}
+
+}
+
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Toon-members] TooN TooN.h internal/dchecktest.hh,
Tom Drummond <=