summaryrefslogtreecommitdiffstatshomepage
path: root/src/emu/debug/debugcon.cpp
diff options
context:
space:
mode:
author ImJezze <jezze@gmx.net>2016-03-02 21:49:49 +0100
committer ImJezze <jezze@gmx.net>2016-03-02 21:49:49 +0100
commit9fe9f6d93e672bcd926f9e7461774bc9cc22e094 (patch)
tree3911b611dd010a4108b90fb8b8c82116eec21117 /src/emu/debug/debugcon.cpp
parentdbdf21ee465acadf3e643d62d6bedfcc297ada85 (diff)
parent1914702e6fae052668df5b068a502bca57c9a3b0 (diff)
Merge remote-tracking branch 'refs/remotes/mamedev/master'
# Resolved Conflicts: # src/osd/modules/render/d3d/d3dhlsl.cpp # src/osd/windows/winmain.cpp
Diffstat (limited to 'src/emu/debug/debugcon.cpp')
-rw-r--r--src/emu/debug/debugcon.cpp44
1 files changed, 14 insertions, 30 deletions
diff --git a/src/emu/debug/debugcon.cpp b/src/emu/debug/debugcon.cpp
index 7bf80dd6118..8aebfd1d979 100644
--- a/src/emu/debug/debugcon.cpp
+++ b/src/emu/debug/debugcon.cpp
@@ -466,39 +466,22 @@ const char *debug_cmderr_to_string(CMDERR error)
***************************************************************************/
/*-------------------------------------------------
- debug_console_printf - printfs the given
+ debug_console_vprintf - vprintfs the given
arguments using the format to the debug
console
-------------------------------------------------*/
-void CLIB_DECL debug_console_printf(running_machine &machine, const char *format, ...)
+void debug_console_vprintf(running_machine &machine, util::format_argument_pack<std::ostream> const &args)
{
- std::string buffer;
- va_list arg;
-
- va_start(arg, format);
- strvprintf(buffer, format, arg);
- va_end(arg);
-
- text_buffer_print(console_textbuf, buffer.c_str());
+ text_buffer_print(console_textbuf, util::string_format(args).c_str());
/* force an update of any console views */
machine.debug_view().update_all(DVT_CONSOLE);
}
-
-/*-------------------------------------------------
- debug_console_vprintf - printfs the given
- arguments using the format to the debug
- console
--------------------------------------------------*/
-
-void CLIB_DECL debug_console_vprintf(running_machine &machine, const char *format, va_list args)
+void debug_console_vprintf(running_machine &machine, util::format_argument_pack<std::ostream> &&args)
{
- std::string buffer;
-
- strvprintf(buffer, format, args);
- text_buffer_print(console_textbuf, buffer.c_str());
+ text_buffer_print(console_textbuf, util::string_format(std::move(args)).c_str());
/* force an update of any console views */
machine.debug_view().update_all(DVT_CONSOLE);
@@ -506,21 +489,22 @@ void CLIB_DECL debug_console_vprintf(running_machine &machine, const char *forma
/*-------------------------------------------------
- debug_console_printf_wrap - printfs the given
+ debug_console_vprintf_wrap - vprintfs the given
arguments using the format to the debug
console
-------------------------------------------------*/
-void CLIB_DECL debug_console_printf_wrap(running_machine &machine, int wrapcol, const char *format, ...)
+void debug_console_vprintf_wrap(running_machine &machine, int wrapcol, util::format_argument_pack<std::ostream> const &args)
{
- std::string buffer;
- va_list arg;
+ text_buffer_print_wrap(console_textbuf, util::string_format(args).c_str(), wrapcol);
- va_start(arg, format);
- strvprintf(buffer, format, arg);
- va_end(arg);
+ /* force an update of any console views */
+ machine.debug_view().update_all(DVT_CONSOLE);
+}
- text_buffer_print_wrap(console_textbuf, buffer.c_str(), wrapcol);
+void debug_console_vprintf_wrap(running_machine &machine, int wrapcol, util::format_argument_pack<std::ostream> &&args)
+{
+ text_buffer_print_wrap(console_textbuf, util::string_format(std::move(args)).c_str(), wrapcol);
/* force an update of any console views */
machine.debug_view().update_all(DVT_CONSOLE);