aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--TODO1
-rw-r--r--src/Makefile.am3
-rw-r--r--src/expressions.cpp5
-rw-r--r--src/interface-ncurses.cpp2
-rw-r--r--src/parser.cpp4
5 files changed, 8 insertions, 7 deletions
diff --git a/TODO b/TODO
index 98198ae..3a91a9d 100644
--- a/TODO
+++ b/TODO
@@ -7,7 +7,6 @@ Known Bugs:
* Scintilla/Scinterm: sometimes <TAB> indents too much (see e.g. state declarations)
* adding a new buffer with syntax highlighting screws up styles:
obviously they are attached to the view instead of the document
- * crashes: 1<(C)>
* reversing EWfilename$ (save as) does not work!
* crashes on large files: S^EM^X$ (regexp: .*)
diff --git a/src/Makefile.am b/src/Makefile.am
index bab79e7..60b866e 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -62,7 +62,8 @@ nodist_sciteco_SOURCES = $(nodist_sciteco_minimal_SOURCES) \
symbols-scintilla.cpp symbols-scilexer.cpp
sciteco_LDADD = $(sciteco_minimal_LDADD)
-CLEANFILES = $(BUILT_SOURCES)
+CLEANFILES = $(BUILT_SOURCES) \
+ symbols-scintilla.cpp symbols-scilexer.cpp
%.c %.h %-private.h : %.gob
@GOB2@ $<
diff --git a/src/expressions.cpp b/src/expressions.cpp
index 03febf1..87785a7 100644
--- a/src/expressions.cpp
+++ b/src/expressions.cpp
@@ -176,9 +176,6 @@ Expressions::eval(bool pop_brace)
gint n = first_op();
Operator op;
- if (n < 2)
- break;
-
op = operators.peek(n);
if (op == OP_LOOP)
break;
@@ -187,6 +184,8 @@ Expressions::eval(bool pop_brace)
pop_op(n);
break;
}
+ if (n < 2)
+ break;
calc();
}
diff --git a/src/interface-ncurses.cpp b/src/interface-ncurses.cpp
index 47d22f6..6215811 100644
--- a/src/interface-ncurses.cpp
+++ b/src/interface-ncurses.cpp
@@ -52,7 +52,7 @@ static void scintilla_notify(Scintilla *sci, int idFrom,
#define UNNAMED_FILE "(Unnamed)"
#define SCI_COLOR_ATTR(f, b) \
- COLOR_PAIR(SCI_COLOR_PAIR(f, b))
+ ((chtype)COLOR_PAIR(SCI_COLOR_PAIR(f, b)))
void
InterfaceNCurses::main(int &argc, char **&argv)
diff --git a/src/parser.cpp b/src/parser.cpp
index d39d9ef..17a11b9 100644
--- a/src/parser.cpp
+++ b/src/parser.cpp
@@ -936,7 +936,9 @@ StateStart::custom(gchar chr)
if (IS_FAILURE(rc)) {
expressions.discard_args();
- g_assert(expressions.pop_op() == Expressions::OP_LOOP);
+ if (expressions.pop_op() != Expressions::OP_LOOP)
+ /* FIXME: what does standard teco say to this */
+ throw Error("Cannot break from loop without loop");
expressions.pop_num(); /* pc */
expressions.pop_num(); /* counter */