Since token_t contains an anonymous union overlaying the integer, flt and string fields, this stores the number read, then immediately overwrites it with a pointer to the static string literal "". You want to remove the token->string = ""; line.

Of course, then your token_print routine will likely crash because it is trying to read the string field even when the token is not a string.