diff options
author | axel <axel@liljencrantz.se> | 2006-05-22 08:16:04 +1000 |
---|---|---|
committer | axel <axel@liljencrantz.se> | 2006-05-22 08:16:04 +1000 |
commit | b746a803a947c1d130aa1f76125ee7d91dced9d5 (patch) | |
tree | 52cd2ae4212c4103b73f3c4d7e9b7e1e0402b717 /expand.h | |
parent | 07e14ed7a85a200c4f8df3d0a47a933e8ff2fe68 (diff) |
Add validator check to make sure the second argument to 'for' is 'in'
darcs-hash:20060521221604-ac50b-5bc4ce217a08304f68b97b20e908ea1279fe26e9.gz
Diffstat (limited to 'expand.h')
-rw-r--r-- | expand.h | 11 |
1 files changed, 11 insertions, 0 deletions
@@ -188,4 +188,15 @@ wchar_t *expand_tilde(wchar_t *in); */ void expand_variable_array( const wchar_t *val, array_list_t *out ); +/** + Test if the specified argument is clean, i.e. it does not contain + any tokens which need to be expanded or otherwise altered. Clean + strings can be passed through expand_string and expand_one without + changing them. About two thirds of all strings are clean, so + skipping expansion on them actually does save a small amount of + time, since it avoids multiple memory allocations during the + expansion process. +*/ +int expand_is_clean( const wchar_t *in ); + #endif |