Instead this would work.

```cpp
             buf->writestring("$(DDOC_EXAMPLES ");
+           buf->printf("%s", utd->comment);
             codebuf.writestring(pre);
             codebuf.writestring(unindent(utd->codedoc));
```

I think trimming spaces is not necessary.