From 7c12de7d3dba6f33e089c489c00d4df975a36011 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Andr=C3=A9=20P=C3=B6nitz?= Date: Tue, 2 Dec 2003 12:02:39 +0000 Subject: [PATCH] * lyxlex_pimpl.[Ch]: don't use '__' in identifiers git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@8181 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/ChangeLog | 2 ++ src/lyxlex_pimpl.C | 20 ++++++++++---------- src/lyxlex_pimpl.h | 8 ++++---- 3 files changed, 16 insertions(+), 14 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 4e118415cc..a3dd0b1679 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -3,6 +3,8 @@ * lyxlex.[Ch]: make interface more similar to std::stream + * lyxlex_pimpl.[Ch]: don't use '__' in identifiers + 2003-12-01 Martin Vermeer * lyxtextclass.[Ch]: add latexparam to CharStyle inset diff --git a/src/lyxlex_pimpl.C b/src/lyxlex_pimpl.C index 4d582a54f3..e1c061d1a7 100644 --- a/src/lyxlex_pimpl.C +++ b/src/lyxlex_pimpl.C @@ -50,7 +50,7 @@ struct compare_tags { LyXLex::Pimpl::Pimpl(keyword_item * tab, int num) - : is(&fb__), table(tab), no_items(num), + : is(&fb_), table(tab), no_items(num), status(0), lineno(0), commentChar('#') { verifyTable(); @@ -138,35 +138,35 @@ bool LyXLex::Pimpl::setFile(string const & filename) // The check only outputs a debug message, because it triggers // a bug in compaq cxx 6.2, where is_open() returns 'true' for // a fresh new filebuf. (JMarc) - if (gz__.is_open() || istream::off_type(is.tellg()) > -1) + if (gz_.is_open() || istream::off_type(is.tellg()) > -1) lyxerr[Debug::LYXLEX] << "Error in LyXLex::setFile: " "file or stream already set." << endl; - gz__.open(filename.c_str(), ios::in); - is.rdbuf(&gz__); + gz_.open(filename.c_str(), ios::in); + is.rdbuf(&gz_); name = filename; lineno = 0; - return gz__.is_open() && is.good(); + return gz_.is_open() && is.good(); } else { lyxerr[Debug::LYXLEX] << "lyxlex: UNcompressed" << endl; // The check only outputs a debug message, because it triggers // a bug in compaq cxx 6.2, where is_open() returns 'true' for // a fresh new filebuf. (JMarc) - if (fb__.is_open() || istream::off_type(is.tellg()) > 0) + if (fb_.is_open() || istream::off_type(is.tellg()) > 0) lyxerr[Debug::LYXLEX] << "Error in LyXLex::setFile: " "file or stream already set." << endl; - fb__.open(filename.c_str(), ios::in); - is.rdbuf(&fb__); + fb_.open(filename.c_str(), ios::in); + is.rdbuf(&fb_); name = filename; lineno = 0; - return fb__.is_open() && is.good(); + return fb_.is_open() && is.good(); } } void LyXLex::Pimpl::setStream(istream & i) { - if (fb__.is_open() || istream::off_type(is.tellg()) > 0) + if (fb_.is_open() || istream::off_type(is.tellg()) > 0) lyxerr[Debug::LYXLEX] << "Error in LyXLex::setStream: " "file or stream already set." << endl; is.rdbuf(i.rdbuf()); diff --git a/src/lyxlex_pimpl.h b/src/lyxlex_pimpl.h index 52ea84d33b..e3109d158f 100644 --- a/src/lyxlex_pimpl.h +++ b/src/lyxlex_pimpl.h @@ -53,10 +53,10 @@ struct LyXLex::Pimpl : boost::noncopyable { bool nextToken(); /// void pushToken(std::string const &); - /// fb__ is only used to open files, the stream is accessed through is. - std::filebuf fb__; - /// gz__ is only used to open files, the stream is accessed through is. - gz::gzstreambuf gz__; + /// fb_ is only used to open files, the stream is accessed through is. + std::filebuf fb_; + /// gz_ is only used to open files, the stream is accessed through is. + gz::gzstreambuf gz_; /// the stream that we use. std::istream is; -- 2.39.2