Following this: Make two-columned list start at same line as its section, I did:




     \begin{tasks}[label = \textbullet](2)
        \task C{}\verb!++!.
        \task German (B1)
        \task Italian (A1)
        \task Greek (native)


which results in the error:

./foo.tex:14: LaTeX Error: \verb illegal in command argument.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.

l.14     \end{tasks}


I read this: How to put \verb command inside of \textbf{} block?, but was still unable to apply the solution, I tried:

\task \cprotect C{}\verb!++!.

but that resulted in:

Runaway argument?
{\task }{,label = \textbullet }{2} \task 
./foo.tex:10: Forbidden control sequence found while scanning use of \tasks.
<inserted text> 
l.10         \task \cprotect

How to fix this?


1 Answer 1


Use this:


But why not a simple C{}\texttt{++}?

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .