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

Unified Diff: tools/gn/parser_unittest.cc

Issue 1869503004: Convert //tools to use std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase, change iwyu fixes for converted directories to include <memory> 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tools/gn/parser.cc ('k') | tools/gn/scope.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/gn/parser_unittest.cc
diff --git a/tools/gn/parser_unittest.cc b/tools/gn/parser_unittest.cc
index b6c200978ccf7ec98649c3ef8a3b83ad4aae0861..39703737a2a8af393cf6b4a60b7c4d07640616d0 100644
--- a/tools/gn/parser_unittest.cc
+++ b/tools/gn/parser_unittest.cc
@@ -26,7 +26,7 @@ void DoParserPrintTest(const char* input, const char* expected) {
ASSERT_TRUE(GetTokens(&input_file, &tokens));
Err err;
- scoped_ptr<ParseNode> result = Parser::Parse(tokens, &err);
+ std::unique_ptr<ParseNode> result = Parser::Parse(tokens, &err);
if (!result)
err.PrintToStdout();
ASSERT_TRUE(result);
@@ -44,7 +44,7 @@ void DoExpressionPrintTest(const char* input, const char* expected) {
ASSERT_TRUE(GetTokens(&input_file, &tokens));
Err err;
- scoped_ptr<ParseNode> result = Parser::ParseExpression(tokens, &err);
+ std::unique_ptr<ParseNode> result = Parser::ParseExpression(tokens, &err);
ASSERT_TRUE(result);
std::ostringstream collector;
@@ -62,7 +62,7 @@ void DoParserErrorTest(const char* input, int err_line, int err_char) {
Err err;
std::vector<Token> tokens = Tokenizer::Tokenize(&input_file, &err);
if (!err.has_error()) {
- scoped_ptr<ParseNode> result = Parser::Parse(tokens, &err);
+ std::unique_ptr<ParseNode> result = Parser::Parse(tokens, &err);
ASSERT_FALSE(result);
ASSERT_TRUE(err.has_error());
}
@@ -80,7 +80,7 @@ void DoExpressionErrorTest(const char* input, int err_line, int err_char) {
Err err;
std::vector<Token> tokens = Tokenizer::Tokenize(&input_file, &err);
if (!err.has_error()) {
- scoped_ptr<ParseNode> result = Parser::ParseExpression(tokens, &err);
+ std::unique_ptr<ParseNode> result = Parser::ParseExpression(tokens, &err);
ASSERT_FALSE(result);
ASSERT_TRUE(err.has_error());
}
« no previous file with comments | « tools/gn/parser.cc ('k') | tools/gn/scope.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698