aboutsummaryrefslogtreecommitdiffstats
path: root/tests/libsample/functions.h
blob: 77b2cb68f6270522d7283a96a6cae06d3d2014a1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
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