Compile the C++ parser library with Sun CC 5.9.

Things you mustn't do:
1) end an enum with a comma

2) #include <cxxxx> and not use std::

3) use anonymous structures

All three things are invalid C++. Anonymous structures inside
anonymous unions are allowed by GCC, but that doesn't mean it's valid.
This commit is contained in:
Thiago Macieira
2009-07-27 21:47:03 +02:00
parent 88549a4b1d
commit d0457b70e3
24 changed files with 321 additions and 306 deletions

View File

@@ -211,7 +211,7 @@ protected:
unsigned line, col;
getTokenStartPosition(index, &line, &col);
QTextCursor tc = _textCursor;
tc.setPosition(tc.document()->findBlockByNumber(line - 1).position() + col + tk.length - 1);
tc.setPosition(tc.document()->findBlockByNumber(line - 1).position() + col + tk.f.length - 1);
return tc;
}
@@ -284,7 +284,7 @@ QTextCursor QuickFixOperation::cursor(unsigned index) const
getTokenStartPosition(index, &line, &col);
QTextCursor tc = _textCursor;
tc.setPosition(tc.document()->findBlockByNumber(line - 1).position() + col - 1);
tc.setPosition(tc.position() + tk.length, QTextCursor::KeepAnchor);
tc.setPosition(tc.position() + tk.f.length, QTextCursor::KeepAnchor);
return tc;
}
@@ -304,7 +304,7 @@ QTextCursor QuickFixOperation::moveAtEndOfToken(unsigned index) const
unsigned line, col;
getTokenStartPosition(index, &line, &col);
QTextCursor tc = _textCursor;
tc.setPosition(tc.document()->findBlockByNumber(line - 1).position() + col + tk.length - 1);
tc.setPosition(tc.document()->findBlockByNumber(line - 1).position() + col + tk.f.length - 1);
return tc;
}