LBPM/IO/PIO.hpp

30 lines
398 B
C++
Raw Normal View History

#ifndef included_PIO_hpp
#define included_PIO_hpp
#include "IO/PIO.h"
2021-03-17 09:24:14 -05:00
#include <cstdio>
#include <iostream>
#include <stdarg.h>
namespace IO {
inline int printp( const char *format, ... )
{
2021-03-17 09:24:14 -05:00
va_list ap;
va_start( ap, format );
char tmp[1024];
2021-03-17 09:24:14 -05:00
int n = vsprintf( tmp, format, ap );
va_end( ap );
pout << tmp;
pout.flush();
return n;
}
2021-03-17 09:24:14 -05:00
} // namespace IO
#endif