mirror of
				https://github.com/janet-lang/janet
				synced 2025-10-31 15:43:01 +00:00 
			
		
		
		
	Update src/core/string.c
Co-authored-by: John W Higgins <wishdev@gmail.com>
This commit is contained in:
		| @@ -582,9 +582,9 @@ static size_t trim_help_leftedge(JanetByteView str, JanetByteView set) { | |||||||
| } | } | ||||||
|  |  | ||||||
| static size_t trim_help_rightedge(JanetByteView str, JanetByteView set) { | static size_t trim_help_rightedge(JanetByteView str, JanetByteView set) { | ||||||
|     for (size_t i = str.len - 1; i > 0; i--) |     for (size_t i = 0; i < str.len; i++) | ||||||
|         if (!trim_help_checkset(set, str.bytes[i])) |         if (!trim_help_checkset(set, str.bytes[str.len - i - 1])) | ||||||
|             return i + 1; |             return str.len - i; | ||||||
|     return 0; |     return 0; | ||||||
| } | } | ||||||
|  |  | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 Calvin Rose
					Calvin Rose