I've used the subcaption package in the past without any problem. But now, i can't use it, which makes it impossible to compile some important documents.
If i try to compile
\documentclass{article}
\usepackage[demo]{graphicx}
\usepackage{caption}
\usepackage[skip=0cm,list=true,labelfont=it]{subcaption}
\begin{document}
\begin{figure}[hptb]
\centering
\begin{tabular}{l l}
\subfloat[\label{fig:g1} Figura 1]
{\resizebox{0.45\textwidth}{!}{\includegraphics{img_a}}} &
\subfloat[\label{fig:g2} Figura 2]
{\resizebox{0.45\textwidth}{!}{\includegraphics{img_a}}} \\
\end{tabular}
\caption{Figure caption.}
\end{figure}
\end{document}
i get the error:
! Undefined control sequence.
l.14 \subfloat
[\label{fig:g1} Figura 1]
From the file log:
This is pdfTeX, Version 3.1415926-2.4-1.40.13 (TeX Live 2012/Debian) (format=latex 2012.9.18)
Package: caption 2012/02/19 v3.2f Customizing captions (AR)
Package: caption3 2012/01/12 v1.4b caption3 kernel (AR)
Package: subcaption 2012/01/12 v1.1d Sub-captions (AR)
Any idea on what the problem might be?


\subfloatappears in the subcaption package just in an error message testing if it is defined and saying subcaption may mot be used with subfig. If you comment out the subcaption line and replace it with\usepackage{subfig}it runs without error, don't know what layout you intended though.... – David Carlisle Sep 18 '12 at 0:18