some more info to minimal example

This commit is contained in:
2025-03-18 13:24:40 +02:00
parent 40d83d563b
commit db4b51ab2d
4 changed files with 17 additions and 2 deletions

View File

@@ -9,12 +9,20 @@ int main(int argc, char *argv[]) {
int modified = -1;
while (modified != 0) {
printf("==========================\n");
printf("main address: %p\n", main);
printf("minimal_lib::getNewValue address: %p\n", minimal_lib::getNewValue);
printf("minimal_lib::otherValue address: %p\n", &minimal_lib::otherValue);
printf("==========================\n");
printf("\n");
modified = minimal_lib::getNewValue(5);
printf("getModified(5): %d\n", modified);
std::this_thread::sleep_for(std::chrono::seconds(1));
printf("otherValue: %d\n", minimal_lib::otherValue);
printf("otherValue: %d\n", minimal_lib::otherValue++);
std::this_thread::sleep_for(std::chrono::seconds(1));
printf("\n");
}
return 0;