You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
int
a_function_to_call()
{
static_value++;
return static_value;
}
int main (int argc, char const *argv[])
{
a_function_to_call();
return 0;
}
Compiling this as a c++ program with -O0 and -g and trying to call or print the function pointer 'a_function_to_call' fails.
Output:
(lldb) b main
(lldb) r
...
(lldb) expression a_function_to_call
error: use of undeclared identifier 'a_function_to_call'
error: 1 errors parsing expression
(lldb) expression a_function_to_call()
error: use of undeclared identifier 'a_function_to_call'
error: 1 errors parsing expression
The text was updated successfully, but these errors were encountered:
Extended Description
Example program:
static int static_value = 0;
int
a_function_to_call()
{
static_value++;
return static_value;
}
int main (int argc, char const *argv[])
{
a_function_to_call();
return 0;
}
Compiling this as a c++ program with -O0 and -g and trying to call or print the function pointer 'a_function_to_call' fails.
Output:
(lldb) b main
(lldb) r
...
(lldb) expression a_function_to_call
error: use of undeclared identifier 'a_function_to_call'
error: 1 errors parsing expression
(lldb) expression a_function_to_call()
error: use of undeclared identifier 'a_function_to_call'
error: 1 errors parsing expression
The text was updated successfully, but these errors were encountered: