View Single Post
Ludak
Member
Join Date: Oct 2014
Old 04-05-2020 , 06:19   Re: String parsing problem
Reply With Quote #5

Quote:
Originally Posted by Fyren View Post
Code:
text[index] == ',' || text[index + 1] == EOS) && parenthesesCounter == 0
This is the expression you're using to determine whether to copy something over into your results. It can only possibly be true when parentheses are balanced. Since your sample input starts with an open parentheses, that means it'll only actually be true at the very end, when the parentheses balance out (and the next character is null for the end of the string).

The code from fysiks doesn't appear to do what you want.
It has worked in AMXX as intended, weird. So I will have to port my own, my own does not parse the last value for some reason.

Last edited by Ludak; 04-05-2020 at 06:20.
Ludak is offline