Debug/3 only comments the first line?

IMHO the spirit of debug/3 is to print just one line of text.

However if a suggestion is to allow it to print multiple lines then instead of a % before each line it might be better to use the multi-line comment /* ... */ as that would make it faster to just wrap the text instead of spending the time to look for line endings. Perhaps an option could be added to state what kind of comments to use, single-line or multi-line.

Remember that the output from using debug/3 is not meant to create more Prolog code but just for review in trying to find a bug. To me the % just signifies to me it is a message from debug/3.

If we are also looking for suggestions for use with debug/3 then instead of basing it on format/3 it could be based on ansi_format/3 (ref) so that color can be added.

Feel free to ignore all of this. :grinning: