aboutsummaryrefslogtreecommitdiffhomepage
path: root/expand.cpp
diff options
context:
space:
mode:
authorGravatar ridiculousfish <corydoras@ridiculousfish.com>2012-01-31 21:30:09 -0800
committerGravatar ridiculousfish <corydoras@ridiculousfish.com>2012-01-31 21:30:09 -0800
commit0b4b6c498d4cac8591dcfc04549acd62305d5008 (patch)
treea8bd71ef0b36a1f265922b98e9e5292b8561d2a4 /expand.cpp
parent409f70c7f3836457cb39113aec36e2c0622e0a61 (diff)
Migrated off of old variant of expand_one that used halloc
Diffstat (limited to 'expand.cpp')
-rw-r--r--expand.cpp41
1 files changed, 0 insertions, 41 deletions
diff --git a/expand.cpp b/expand.cpp
index cadab4ad..122876e9 100644
--- a/expand.cpp
+++ b/expand.cpp
@@ -1809,47 +1809,6 @@ int expand_string2( const wcstring &input, std::vector<completion_t> &output, in
return res;
}
-wchar_t *expand_one( void *context, const wchar_t *string, int flags )
-{
- std::vector<completion_t> l;
- int res;
- wchar_t *one;
-
- CHECK( string, 0 );
-
- if( (!(flags & ACCEPT_INCOMPLETE)) && expand_is_clean( string ) )
- {
- halloc_register( context, (void *)string );
- return (wchar_t *)string;
- }
-
-// al_init( &l );
- res = expand_string2( string, l, flags );
- if( !res )
- {
- one = 0;
- }
- else
- {
- if( l.size() != 1 )
- {
- one=0;
- }
- else
- {
- one = wcsdup( l.at(0).completion.c_str() );
-// al_set( &l, 0, 0 );
- }
- }
-
-// al_foreach( &l, &free );
-// al_destroy( &l );
-
- if (context)
- halloc_register( context, one );
- return one;
-}
-
bool expand_one(wcstring &string, int flags) {
std::vector<completion_t> completions;
bool result = false;