diff options
Diffstat (limited to 'lldb/test/expression_command/call-function/main.cpp')
| -rw-r--r-- | lldb/test/expression_command/call-function/main.cpp | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/lldb/test/expression_command/call-function/main.cpp b/lldb/test/expression_command/call-function/main.cpp index ca43c2eabe5..9b494c712bc 100644 --- a/lldb/test/expression_command/call-function/main.cpp +++ b/lldb/test/expression_command/call-function/main.cpp @@ -1,5 +1,6 @@ #include <iostream> #include <string> +#include <cstring> struct Five { @@ -14,6 +15,30 @@ returnsFive() return my_five; } +unsigned int +fib(unsigned int n) +{ + if (n < 2) + return n; + else + return fib(n - 1) + fib(n - 2); +} + +int +add(int a, int b) +{ + return a + b; +} + +bool +stringCompare(const char *str) +{ + if (strcmp( str, "Hello world" ) == 0) + return true; + else + return false; +} + int main (int argc, char const *argv[]) { std::string str = "Hello world"; |

