I'm still having a hard time groking end > start.  The typical pattern is to say start < end, its easier to visualize.

I think we can also drop out a subtraction instruction from the inner loop here if we are a bit smarter about how we handle the bounds:

  int ptr = end - 1;
  while (start <= ptr && isWhitespace(raw[ptr]))
    ptr--;
  return ptr + 1;