aboutsummaryrefslogtreecommitdiffstats
path: root/tests/libsample/functions.h
diff options
context:
space:
mode:
Diffstat (limited to 'tests/libsample/functions.h')
-rw-r--r--tests/libsample/functions.h36
1 files changed, 36 insertions, 0 deletions
diff --git a/tests/libsample/functions.h b/tests/libsample/functions.h
new file mode 100644
index 000000000..77b2cb68f
--- /dev/null
+++ b/tests/libsample/functions.h
@@ -0,0 +1,36 @@
+#ifndef FUNCTIONS_H
+#define FUNCTIONS_H
+
+#include <list>
+#include <utility>
+#include "complex.h"
+
+enum GlobalEnum {
+ NoThing,
+ FirstThing,
+ SecondThing,
+ ThirdThing
+};
+
+enum GlobalPolyFuncEnum {
+ GlobalPolyFunc_i,
+ GlobalPolyFunc_d
+};
+
+void printSomething();
+int gimmeInt();
+double gimmeDouble();
+double multiplyPair(std::pair<double, double> pair);
+std::list<Complex> gimmeComplexList();
+Complex sumComplexPair(std::pair<Complex, Complex> cpx_pair);
+
+int countCharacters(const char* text);
+char* makeCString();
+const char* returnCString();
+
+// Tests polymorphism on functions (!methods)
+GlobalPolyFuncEnum polymorphicFunc(int val);
+GlobalPolyFuncEnum polymorphicFunc(double val);
+
+#endif // FUNCTIONS_H
+