Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(186)

Side by Side Diff: src/IceBrowserCompileServer.cpp

Issue 1838753002: Subzero: Remove IceString. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Code review changes Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/IceBrowserCompileServer.h ('k') | src/IceCfg.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 //===- subzero/src/IceBrowserCompileServer.cpp - Browser compile server ---===// 1 //===- subzero/src/IceBrowserCompileServer.cpp - Browser compile server ---===//
2 // 2 //
3 // The Subzero Code Generator 3 // The Subzero Code Generator
4 // 4 //
5 // This file is distributed under the University of Illinois Open Source 5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details. 6 // License. See LICENSE.TXT for details.
7 // 7 //
8 //===----------------------------------------------------------------------===// 8 //===----------------------------------------------------------------------===//
9 /// 9 ///
10 /// \file 10 /// \file
(...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after
179 // If there was an earlier error, do not attempt to push bytes to the 179 // If there was an earlier error, do not attempt to push bytes to the
180 // QueueStreamer. Otherwise the thread could become blocked. 180 // QueueStreamer. Otherwise the thread could become blocked.
181 if (HadError.load()) 181 if (HadError.load())
182 return true; 182 return true;
183 return InputStream->PutBytes( 183 return InputStream->PutBytes(
184 const_cast<unsigned char *>( 184 const_cast<unsigned char *>(
185 reinterpret_cast<const unsigned char *>(Data)), 185 reinterpret_cast<const unsigned char *>(Data)),
186 NumBytes) != NumBytes; 186 NumBytes) != NumBytes;
187 } 187 }
188 188
189 void BrowserCompileServer::setFatalError(const IceString &Reason) { 189 void BrowserCompileServer::setFatalError(const std::string &Reason) {
190 HadError.store(true); 190 HadError.store(true);
191 Ctx->getStrError() << Reason; 191 Ctx->getStrError() << Reason;
192 // Make sure that the QueueStreamer is not stuck by signaling an early end. 192 // Make sure that the QueueStreamer is not stuck by signaling an early end.
193 InputStream->SetDone(); 193 InputStream->SetDone();
194 } 194 }
195 195
196 ErrorCode &BrowserCompileServer::getErrorCode() { 196 ErrorCode &BrowserCompileServer::getErrorCode() {
197 if (HadError.load()) { 197 if (HadError.load()) {
198 // HadError means report_fatal_error is called. Make sure that the 198 // HadError means report_fatal_error is called. Make sure that the
199 // LastError is not EC_None. We don't know the type of error so just pick 199 // LastError is not EC_None. We don't know the type of error so just pick
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
240 llvm::report_fatal_error("no browser hookups"); 240 llvm::report_fatal_error("no browser hookups");
241 } 241 }
242 242
243 ErrorCode &BrowserCompileServer::getErrorCode() { 243 ErrorCode &BrowserCompileServer::getErrorCode() {
244 llvm::report_fatal_error("no browser hookups"); 244 llvm::report_fatal_error("no browser hookups");
245 } 245 }
246 246
247 } // end of namespace Ice 247 } // end of namespace Ice
248 248
249 #endif // PNACL_BROWSER_TRANSLATOR 249 #endif // PNACL_BROWSER_TRANSLATOR
OLDNEW
« no previous file with comments | « src/IceBrowserCompileServer.h ('k') | src/IceCfg.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698