\documentclass{article}


\usepackage{amsmath}

\begin{document}

\[
\genfrac[]{1pt}{}{a}{b}\quad  
\genfrac{\{}{\}}{0pt}{2}{a}{b}\quad 
\genfrac{|}{|}{}{1}{a}{b}\quad 
\genfrac(){}{}pq
\]

\end{document}
