Cleaned up many error codes. For any who is filling in error strings into
lldb_private::Error objects the rules are:
- short strings that don't start with a capitol letter unless the name is a
  class or anything else that is always capitolized
- no trailing newline character
- should be one line if possible

Implemented a first pass at adding "--gdb-format" support to anything that
accepts format with optional size/count.



git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@142999 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/source/Commands/CommandObjectTarget.cpp b/source/Commands/CommandObjectTarget.cpp
index b5c3a4c..89653b7 100644
--- a/source/Commands/CommandObjectTarget.cpp
+++ b/source/Commands/CommandObjectTarget.cpp
@@ -1880,7 +1880,7 @@
                     break;
                     
                 default:
-                    error.SetErrorStringWithFormat("Invalid short option character '%c'.\n", short_option);
+                    error.SetErrorStringWithFormat("invalid short option character '%c'", short_option);
                     break;
                     
             }
@@ -2644,7 +2644,7 @@
                 if (!success)
                 {
                     Error error;
-                    error.SetErrorStringWithFormat("Invalid address: \"%s\".", option_arg);
+                    error.SetErrorStringWithFormat("invalid address: \"%s\"", option_arg);
                 }
             }
             else
@@ -2985,13 +2985,13 @@
                     m_type = eLookupTypeAddress;
                     m_addr = Args::StringToUInt64(option_arg, LLDB_INVALID_ADDRESS);
                     if (m_addr == LLDB_INVALID_ADDRESS)
-                        error.SetErrorStringWithFormat ("Invalid address string '%s'.\n", option_arg);
+                        error.SetErrorStringWithFormat ("invalid address string '%s'", option_arg);
                     break;
                     
                 case 'o':
                     m_offset = Args::StringToUInt64(option_arg, LLDB_INVALID_ADDRESS);
                     if (m_offset == LLDB_INVALID_ADDRESS)
-                        error.SetErrorStringWithFormat ("Invalid offset string '%s'.\n", option_arg);
+                        error.SetErrorStringWithFormat ("invalid offset string '%s'", option_arg);
                     break;
                     
                 case 's':
@@ -3011,9 +3011,9 @@
                 case 'l':
                     m_line_number = Args::StringToUInt32(option_arg, UINT32_MAX);
                     if (m_line_number == UINT32_MAX)
-                        error.SetErrorStringWithFormat ("Invalid line number string '%s'.\n", option_arg);
+                        error.SetErrorStringWithFormat ("invalid line number string '%s'", option_arg);
                     else if (m_line_number == 0)
-                        error.SetErrorString ("Zero is an invalid line number.");
+                        error.SetErrorString ("zero is an invalid line number");
                     m_type = eLookupTypeFileLine;
                     break;
                     
@@ -3434,7 +3434,7 @@
                     m_line_end = Args::StringToUInt32 (option_arg, UINT_MAX, 0, &success);
                     if (!success)
                     {
-                        error.SetErrorStringWithFormat ("Invalid end line number: \"%s\".", option_arg);
+                        error.SetErrorStringWithFormat ("invalid end line number: \"%s\"", option_arg);
                         break;
                     }
                     m_sym_ctx_specified = true;
@@ -3444,7 +3444,7 @@
                     m_line_start = Args::StringToUInt32 (option_arg, 0, 0, &success);
                     if (!success)
                     {
-                        error.SetErrorStringWithFormat ("Invalid start line number: \"%s\".", option_arg);
+                        error.SetErrorStringWithFormat ("invalid start line number: \"%s\"", option_arg);
                         break;
                     }
                     m_sym_ctx_specified = true;
@@ -3468,7 +3468,7 @@
                 {
                     m_thread_id = Args::StringToUInt64(option_arg, LLDB_INVALID_THREAD_ID, 0);
                     if (m_thread_id == LLDB_INVALID_THREAD_ID)
-                       error.SetErrorStringWithFormat ("Invalid thread id string '%s'.\n", option_arg);
+                       error.SetErrorStringWithFormat ("invalid thread id string '%s'", option_arg);
                     m_thread_specified = true;
                 }
                 break;
@@ -3484,7 +3484,7 @@
                 {
                     m_thread_index = Args::StringToUInt32(option_arg, UINT32_MAX, 0);
                     if (m_thread_id == UINT32_MAX)
-                       error.SetErrorStringWithFormat ("Invalid thread index string '%s'.\n", option_arg);
+                       error.SetErrorStringWithFormat ("invalid thread index string '%s'", option_arg);
                     m_thread_specified = true;
                 }
                 break;
@@ -3493,7 +3493,7 @@
                     m_one_liner = option_arg;
                 break;
                 default:
-                    error.SetErrorStringWithFormat ("Unrecognized option %c.", short_option);
+                    error.SetErrorStringWithFormat ("unrecognized option %c.", short_option);
                 break;
             }
             return error;