mail[Wesnoth-commits] r44956 - /trunk/src/serialization/preprocessor.cpp


Others Months | Index by Date | Thread Index
>>   [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Header


Content

Posted by alinktomine on July 31, 2010 - 08:52:
Author: alink
Date: Sat Jul 31 08:52:06 2010
New Revision: 44956

URL: http://svn.gna.org/viewcvs/wesnoth?rev=44956&view=rev
Log:
Optimize cache building (-30%).
Stop writing never read debug data. It was only output in cfg.plain (produced 
by --preprocess) where it filled 3/4 of the file with useless spam.

Modified:
    trunk/src/serialization/preprocessor.cpp

Modified: trunk/src/serialization/preprocessor.cpp
URL: 
http://svn.gna.org/viewcvs/wesnoth/trunk/src/serialization/preprocessor.cpp?rev=44956&r1=44955&r2=44956&view=diff
==============================================================================
--- trunk/src/serialization/preprocessor.cpp (original)
+++ trunk/src/serialization/preprocessor.cpp Sat Jul 31 08:52:06 2010
@@ -374,9 +374,6 @@
 preprocessor::~preprocessor()
 {
        assert(target_.current_ == this);
-       if (!old_location_.empty()) {
-               target_.buffer_ << "\376line " << old_linenum_ << ' ' << 
old_location_ << '\n';
-       }
        if (!old_textdomain_.empty() && target_.textdomain_ != 
old_textdomain_) {
                target_.buffer_ << "\376textdomain " << old_textdomain_ << 
'\n';
        }
@@ -549,7 +546,6 @@
        t.location_ = s.str();
        t.linenum_ = linenum;
 
-       t.buffer_ << "\376line " << linenum << ' ' << t.location_ << '\n';
        if (t.textdomain_ != domain) {
                t.buffer_ << "\376textdomain " << domain << '\n';
                t.textdomain_ = domain;
@@ -569,8 +565,7 @@
        tokens_.push_back(token);
        std::ostringstream s;
        if (!skipping_ && slowpath_) {
-               s << "\376line " << linenum_ << ' ' << target_.location_
-                 << "\n\376textdomain " << target_.textdomain_ << '\n';
+               s << "\376textdomain " << target_.textdomain_ << '\n';
        }
        strings_.push_back(s.str());
 }
@@ -660,9 +655,6 @@
                target_.linenum_ = cond_linenum;
                if (diff <= target_.location_.size() + 11) {
                        target_.buffer_ << std::string(diff, '\n');
-               } else {
-                       target_.buffer_ << "\376line " << target_.linenum_
-                               << ' ' << target_.location_ << '\n';
                }
        }
 
@@ -941,8 +933,7 @@
                                        target_.error(error.str(), linenum_);
                                }
                                std::ostringstream v;
-                               v << arg->second << "\376line " << linenum_ 
<< ' ' << target_.location_
-                                 << "\n\376textdomain " << 
target_.textdomain_ << '\n';
+                               v << arg->second << "\376textdomain " << 
target_.textdomain_ << '\n';
                                pop_token();
                                put(v.str());
                        }




Related Messages


Powered by MHonArc, Updated Sat Jul 31 09:00:16 2010