summaryrefslogtreecommitdiff
path: root/tests/test.cpp
blob: 5538ba88b3b74658cde180fa32dc624c0be03eed (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
#include <iostream>
#include <string>

namespace my_namespace {
    void namespaced_function() {
        std::cout << "Namespaced function" << std::endl;
    }

    class MyClass {
    public:
        void myMethod() {
            std::cout << "Method inside class" << std::endl;
        }
    };
}

struct MyStruct {
    int x;
    void structMethod() {
        std::cout << "Method inside struct" << std::endl;
    }
};

void global_hello() {
    std::cout << "Global hello" << std::endl;
}

int main() {
    global_hello();
    my_namespace::namespaced_function();
    return 0;
}