c-fill-paragraph

c-fill-paragraph is an interactive compiled Lisp function in `cc-cmds.el'.


(c-fill-paragraph &optional ARG)

Like M-q but handles C and C++ style comments.
If any of the current line is a comment or within a comment, fill the
comment or the paragraph of it that point is in, preserving the
comment indentation or line-starting decorations (see the
`c-comment-prefix-regexp' and `c-block-comment-prefix' variables for
details).

If point is inside multiline string literal, fill it. This currently
does not respect escaped newlines, except for the special case when it
is the very first thing in the string. The intended use for this rule
is in situations like the following:

char description[] = "\
A very long description of something that you want to fill to make
nicely formatted output.";

If point is in any other situation, i.e. in normal code, do nothing.

Optional prefix ARG means justify paragraph as well.