diff options
author | ridiculousfish <corydoras@ridiculousfish.com> | 2012-05-17 19:46:08 -0700 |
---|---|---|
committer | ridiculousfish <corydoras@ridiculousfish.com> | 2012-05-17 19:46:08 -0700 |
commit | da6295c428271e34a9e03ce7858e12a2892dff44 (patch) | |
tree | 06075412bff755876a706ee17a336b8666f37b65 /complete.cpp | |
parent | 86645b32e172301088517bfb860b2e0990b3e5ec (diff) |
More work towards getting function.h off of shared_ptr
Diffstat (limited to 'complete.cpp')
-rw-r--r-- | complete.cpp | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/complete.cpp b/complete.cpp index 35e0a5eb..e4602adb 100644 --- a/complete.cpp +++ b/complete.cpp @@ -986,14 +986,10 @@ void completer_t::complete_cmd_desc( const wcstring &str ) static wcstring complete_function_desc( const wcstring &fn ) { wcstring result; - - const wchar_t *res = function_get_desc( fn ); - if (res) { - result = res; - } else { + bool has_description = function_get_desc(fn, &result); + if (! has_description) { function_get_definition(fn, &result); } - return result; } |