Revert "Expose GetLineSeparatorForLanguage in address_formatter.h"

This reverts revision
https://code.google.com/p/libaddressinput/source/detail?r=305.

TBR=lararennie@google.com

Review URL: https://codereview.appspot.com/118800043

git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@306 38ededc0-08b8-5190-f2ac-b31f878777ad
Fix memory corruption bug in LookupKey::FromLookupKey().

Copy nodes_ only if other object is a different object.

R=rouslan@chromium.org
BUG=

Review URL: https://codereview.appspot.com/117950046

git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@307 38ededc0-08b8-5190-f2ac-b31f878777ad
Clean up dependencies.

- Remove unused #include statements.
- Add missing #include statements.
- Remove unused forward declarations.
- Add missing forward declarations.
- Group and sort #include and using statements consistently.

R=rouslan@chromium.org
BUG=

Review URL: https://codereview.appspot.com/112450046

git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@308 38ededc0-08b8-5190-f2ac-b31f878777ad
Store all callbacks as const scoped_ptr<const Callback>.

R=rouslan@chromium.org
BUG=

Review URL: https://codereview.appspot.com/116010043

git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@309 38ededc0-08b8-5190-f2ac-b31f878777ad
Do not go past the end of an empty vector in CombineLinesForLanguage.

TBR=lararennie@google.com

Review URL: https://codereview.appspot.com/115120043

git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@310 38ededc0-08b8-5190-f2ac-b31f878777ad
Use string literals instead of dynamically concatenating std::string.

R=rouslan@chromium.org
BUG=

Review URL: https://codereview.appspot.com/118910043

git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@311 38ededc0-08b8-5190-f2ac-b31f878777ad
Merge third_party/libaddressinput/src from https://chromium.googlesource.com/external/libaddressinput.git at 5511bc1d716b300f126b3641bbfa15068dce85c8

This commit was generated by merge_from_chromium.py.

Change-Id: I7468a7e7638ead9ec264c75eee3f36ce6293453a
Get rid of BuildCallback() helper functions.

Replace them with const Callback objects created in the constructor.
(This is simpler, and the way most of the code already does it.)

R=rouslan@chromium.org
BUG=

Review URL: https://codereview.appspot.com/116980043

git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@312 38ededc0-08b8-5190-f2ac-b31f878777ad
Add assert(this != &rule) in Rule::CopyFrom().

It does not make any sense to copy a Rule object onto itself.

R=rouslan@chromium.org
BUG=

Review URL: https://codereview.appspot.com/115150043

git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@313 38ededc0-08b8-5190-f2ac-b31f878777ad
Improved code formatting.

These changes were created using the clang-format tool, and then
manually selecting from the changes made by the tool.

R=rouslan@chromium.org
BUG=

Review URL: https://codereview.appspot.com/118080043

git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@314 38ededc0-08b8-5190-f2ac-b31f878777ad
Hex escape all UTF-8 string literals.

This is necessary for compatibility with broken compilers.

R=rouslan@chromium.org
BUG=

Review URL: https://codereview.appspot.com/114280043

git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@315 38ededc0-08b8-5190-f2ac-b31f878777ad
A poor man's release-time assert for failing to open the test data file.

This patch prevents running unit tests from an incorrect directory in
release mode. Release mode builds ignore assert(file.is_open()) for the
test data file, which causes many hard-to-diagnose crashes due to the
rest of the code relying on that file being open. See
http://crbug.com/395169 and http://crbug.com/396203 for examples.

R=roubert@google.com

Review URL: https://codereview.appspot.com/116200043

git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@316 38ededc0-08b8-5190-f2ac-b31f878777ad
Make JSON methods pass thru to the implementation.

R=roubert@google.com

Review URL: https://codereview.appspot.com/115210043

git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@317 38ededc0-08b8-5190-f2ac-b31f878777ad
Simplified memory management in class Json.

By making JsonImpl a friend class and providing a private constructor
that it can call to create new Json objects that initialize their impl_
member in the constructor, it becomes possible to store newly created
Json objects directly into dictionaries_ to simplify program flow.

R=rouslan@chromium.org
BUG=

Review URL: https://codereview.appspot.com/113480043

git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@318 38ededc0-08b8-5190-f2ac-b31f878777ad
Reduce number of string copies and map lookups in FakeDownloader.

R=roubert@google.com

Review URL: https://codereview.appspot.com/117140043

git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@319 38ededc0-08b8-5190-f2ac-b31f878777ad
Add assertion on testdata/countryinfo.txt sorting.

This will prevent silently creating bogus keys in FakeDownloader if the
sorting isn't as expected.

R=rouslan@chromium.org
BUG=

Review URL: https://codereview.appspot.com/113530043

git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@320 38ededc0-08b8-5190-f2ac-b31f878777ad
Updated RegionDataConstants for UA.

git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@321 38ededc0-08b8-5190-f2ac-b31f878777ad
Merge third_party/libaddressinput/src from https://chromium.googlesource.com/external/libaddressinput.git at d75941244491c922456bf0fa4a987c098f082a76

This commit was generated by merge_from_chromium.py.

Change-Id: I705206ae4461b34c2863fc1b0fe69421625a901c
Improve efficiency of PreloadSupplier and RegionDataBuilder.

before: RegionDataBuilderTest.BuildCnRegionTree (8485 ms)
after: RegionDataBuilderTest.BuildCnRegionTree (5765 ms)
 => 32% improvement.

(Built using 'g++ -g -pg -O0')

R=roubert@google.com

Review URL: https://codereview.appspot.com/111390043

git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@322 38ededc0-08b8-5190-f2ac-b31f878777ad
Formatting inline street addresses.

Côte d’Ivoire uses "%N%n%O%n%X %A %C %X" address format, which has
inline street address. This patch fixes formatting for inline street
addresses. There is no support for multiple street address lines with
such format.

R=lararennie@google.com, roubert@google.com

Review URL: https://codereview.appspot.com/120310043

git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@323 38ededc0-08b8-5190-f2ac-b31f878777ad