From 0b1a312de28759b86e2141b09874ab1a80b043ee Mon Sep 17 00:00:00 2001 From: Egor Tensin Date: Sun, 13 Sep 2020 13:05:16 +0300 Subject: call_stack: try to fix __declspec(noinline) #2 --- test/call_stack.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'test') diff --git a/test/call_stack.cpp b/test/call_stack.cpp index a96b6a8..082ff3a 100644 --- a/test/call_stack.cpp +++ b/test/call_stack.cpp @@ -13,18 +13,19 @@ void call_stack() { call_stack.dump(boost::nowide::cout, dbghelp); } +// Some tricks to prevent the functions from being inlined follow... BOOST_NOINLINE void baz() { - boost::nowide::cout << "baz\n"; + boost::nowide::cout << "baz " << &baz << '\n'; call_stack(); } BOOST_NOINLINE void bar() { - boost::nowide::cout << "bar\n"; + boost::nowide::cout << "bar " << &bar << '\n'; baz(); } BOOST_NOINLINE void foo() { - boost::nowide::cout << "foo\n"; + boost::nowide::cout << "foo " << &foo << '\n'; bar(); } -- cgit v1.2.3