From 38fcf6d15cdf09591e7d7a142ad724164875e433 Mon Sep 17 00:00:00 2001 From: Robin Haberkorn Date: Sun, 16 Nov 2014 19:31:29 +0100 Subject: rewritten View and Interface base classes using the Curiously Recurring Template Pattern. * without the one-view-per-buffer designs, many Scintilla send message (SSM) calls could be inlined * with the new design, this was no longer possible using the abstract base classes. the CRT pattern allows inlining again but introduces a strange level of code obscurity. * tests suggest that at high optimization levels, the one-view-per-buffer design and the CRT pattern reduces typical macro runtimes by 30% (e.g. for symbols-extract.tes). * only updated the NCurses UI for the time being --- src/error.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src/error.cpp') diff --git a/src/error.cpp b/src/error.cpp index a76d0e1..7bdd6f2 100644 --- a/src/error.cpp +++ b/src/error.cpp @@ -55,7 +55,7 @@ Error::QRegFrame::copy() const void Error::QRegFrame::display(gint nr) { - interface.msg(Interface::MSG_INFO, + interface.msg(InterfaceCurrent::MSG_INFO, "#%d in Q-Register \"%s\" at %d (%d:%d)", nr, name, pos, line, column); } @@ -75,7 +75,7 @@ Error::FileFrame::copy() const void Error::FileFrame::display(gint nr) { - interface.msg(Interface::MSG_INFO, + interface.msg(InterfaceCurrent::MSG_INFO, "#%d in file \"%s\" at %d (%d:%d)", nr, name, pos, line, column); } @@ -95,7 +95,7 @@ Error::ToplevelFrame::copy() const void Error::ToplevelFrame::display(gint nr) { - interface.msg(Interface::MSG_INFO, + interface.msg(InterfaceCurrent::MSG_INFO, "#%d in toplevel macro at %d (%d:%d)", nr, pos, line, column); } @@ -136,7 +136,7 @@ Error::add_frame(Frame *frame) void Error::display_short(void) { - interface.msg(Interface::MSG_ERROR, + interface.msg(InterfaceCurrent::MSG_ERROR, "%s (at %d)", description, pos); } @@ -145,7 +145,7 @@ Error::display_full(void) { gint nr = 0; - interface.msg(Interface::MSG_ERROR, "%s", description); + interface.msg(InterfaceCurrent::MSG_ERROR, "%s", description); frames = g_slist_reverse(frames); for (GSList *cur = frames; cur; cur = g_slist_next(cur)) { -- cgit v1.2.3