Here below are codes for two latex tables (generated by pandoc with a lua filter).  The first table renders perfectly.  The second nested table throws an error.  Can you help diagnose the problem?

THE LUA FILTER:
function RawBlock (raw)
  if raw.format:match 'html' then
    return pandoc.read(raw.text, 'html').blocks
  end
end

THE ERROR MESSAGE:
Runaway argument?
\global \advance \c@LT@chunks \@ne \global \LT@rows \z@ \setbox \z@ \vbox \ETC.
! Forbidden control sequence found while scanning use of \LT@nofcols.
<inserted text>
\par
l.176 \begin{longtable}[]{@{}rrr@{}} 

TABLE 1:
\begin{longtable}[]{@{}rrr@{}}
\caption{This is a Caption}\tabularnewline
\toprule
a & b & c \\
\midrule
\endfirsthead
\toprule
a & b & c \\
\midrule
\endhead
1 & 10 & 100 \\
2 & 20 & 200 \\
3 & 30 & 300 \\
\bottomrule
\end{longtable} 

TABLE 2 (a table of 2 tables):
\begin{longtable}[]{@{}
  >{\raggedright\arraybackslash}p{(\columnwidth - 2\tabcolsep) * \real{0.5000}}
  >{\raggedright\arraybackslash}p{(\columnwidth - 2\tabcolsep) * \real{0.5000}}@{}}
\toprule
\endhead
\begin{minipage}[t]{\linewidth}\raggedright
\begin{longtable}[]{@{}rrr@{}}
\caption{\textbf{This is a Caption}}\tabularnewline
\toprule
a & b & c \\
\midrule
\endfirsthead
\toprule
a & b & c \\
\midrule
\endhead
1 & 10 & 100 \\
2 & 20 & 200 \\
3 & 30 & 300 \\
\bottomrule
\end{longtable}
\end{minipage} & \begin{minipage}[t]{\linewidth}\raggedright
\begin{longtable}[]{@{}rrr@{}}
\caption{\textbf{This is Another Caption}}\tabularnewline
\toprule
a & b & c \\
\midrule
\endfirsthead
\toprule
a & b & c \\
\midrule
\endhead
2 & 20 & 200 \\
4 & 40 & 400 \\
6 & 60 & 600 \\
\bottomrule
\end{longtable}
\end{minipage} \\
\bottomrule
\end{longtable}

 

--
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/6bde11a6-701b-4ceb-8664-0f7348bd4b4fn%40googlegroups.com.