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

Unified Diff: url/scheme_host_port.h

Issue 1542703002: Switch to standard integer types in url/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years 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 | « url/origin_unittest.cc ('k') | url/scheme_host_port.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: url/scheme_host_port.h
diff --git a/url/scheme_host_port.h b/url/scheme_host_port.h
index 3aca558172d5d42919864de936274eae2345ecf4..47a9041e2afd8e1db1b92654b0d72cfddef9bdd4 100644
--- a/url/scheme_host_port.h
+++ b/url/scheme_host_port.h
@@ -5,9 +5,10 @@
#ifndef URL_SCHEME_HOST_PORT_H_
#define URL_SCHEME_HOST_PORT_H_
+#include <stdint.h>
+
#include <string>
-#include "base/basictypes.h"
#include "base/strings/string_piece.h"
#include "url/url_export.h"
@@ -81,7 +82,9 @@ class URL_EXPORT SchemeHostPort {
// support ports (e.g. 'file'). In that case, |port| must be 0.
//
// Copies the data in |scheme| and |host|.
- SchemeHostPort(base::StringPiece scheme, base::StringPiece host, uint16 port);
+ SchemeHostPort(base::StringPiece scheme,
+ base::StringPiece host,
+ uint16_t port);
// Creates a (scheme, host, port) tuple from |url|, as described at
// https://tools.ietf.org/html/rfc6454#section-4
@@ -97,7 +100,7 @@ class URL_EXPORT SchemeHostPort {
// and all IPv6 addresses will be enclosed in brackets ("[2001:db8::1]").
const std::string& host() const { return host_; }
const std::string& scheme() const { return scheme_; }
- uint16 port() const { return port_; }
+ uint16_t port() const { return port_; }
bool IsInvalid() const;
// Serializes the SchemeHostPort tuple to a canonical form.
@@ -123,7 +126,7 @@ class URL_EXPORT SchemeHostPort {
private:
std::string scheme_;
std::string host_;
- uint16 port_;
+ uint16_t port_;
};
} // namespace url
« no previous file with comments | « url/origin_unittest.cc ('k') | url/scheme_host_port.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698