
The differentiation was originally done in the pasteString function, so that's where I generalized it until it did what it should do. But I agree that the way you suggest would be more elegant. An more thorough solution would be to make (readP_to_S parseKey) return non-zero for whitespace chars. Anyway, please feel free to improve. I'd be happy to test better patches.
Daan
* on Tuesday, 08.10.13 at 14:22, Daniel Wagner
Hi Daan,
The idea of this patch looks good to me, but the implementation looks a bit strange. Maybe these cases could be added to pasteChar with pattern-matching instead of pasteString with if/then/else... what do you think? I'm happy to be convinced otherwise.
~d
On 2013-10-08 01:43, Daan van Rossum wrote:
This patch fixes pasting strings that contain whitespace characters
-- Daan van Rossum