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

Unified Diff: base/cpp101/hello_world.cc

Issue 23567011: Example solution for C++ 101 Exercise 0 (hello world) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Sync to 224002 Created 7 years, 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « base/base.gyp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/cpp101/hello_world.cc
diff --git a/ui/gfx/text_utils_android.cc b/base/cpp101/hello_world.cc
similarity index 55%
copy from ui/gfx/text_utils_android.cc
copy to base/cpp101/hello_world.cc
index c564b9b1db0e2ce096f1265547a614a94e70bda7..eb0940ef582d0c901af358a632e65dd3eca7f348 100644
--- a/ui/gfx/text_utils_android.cc
+++ b/base/cpp101/hello_world.cc
@@ -2,15 +2,12 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "ui/gfx/text_utils.h"
+#include <stdio.h>
#include "base/logging.h"
-namespace gfx {
-
-int GetStringWidth(const base::string16& text, const FontList& font_list) {
- NOTIMPLEMENTED();
+int main(int argc, char* argv[]) {
+ CHECK_GT(puts("Hello, world!"), 0);
+ LOG(INFO) << "Hello, logging!";
return 0;
}
-
-} // namespace gfx
« no previous file with comments | « base/base.gyp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698