Rename Optimize's errMessages to messages

This parameter can contain both errors and warnings, so calling it errMessages is confusing as the user only expects to see errors here.

Ideally this rename should be propagated to the lower layers of the implementation,
but the public header change is the most useful part.

Change-Id: I062564cf38d36f950adfa7c37c090b189e068134
diff --git a/include/armnn/INetwork.hpp b/include/armnn/INetwork.hpp
index 1041492..6efc84f 100644
--- a/include/armnn/INetwork.hpp
+++ b/include/armnn/INetwork.hpp
@@ -568,7 +568,7 @@
 /// @param network INetwork description of the network to be optimized.
 /// @param backendPreferences The choice of the backend ordered by user preferences.
 /// @param deviceSpec DeviceSpec object as queried from the runtime. See IRuntime::GetDeviceSpec()
-/// @param errMessages if there are failures or warnings a string describing same will be added to the vector
+/// @param messages If there are failures or warnings a string describing same will be added to the vector
 /// @param options OptimizerOptions object with optimizer configuration options
 /// @return An IOptimizedNetworkPtr interface to the optimized network, throws an exception derived from
 /// armnn::Exception if process fails.
@@ -577,5 +577,5 @@
                               const std::vector<BackendId>& backendPreferences,
                               const IDeviceSpec& deviceSpec,
                               const OptimizerOptions& options = OptimizerOptions(),
-                              Optional<std::vector<std::string>&> errMessages = EmptyOptional());
+                              Optional<std::vector<std::string>&> messages = EmptyOptional());
 } //namespace armnn
diff --git a/src/armnn/Network.cpp b/src/armnn/Network.cpp
index a708361..f4bfc7a 100644
--- a/src/armnn/Network.cpp
+++ b/src/armnn/Network.cpp
@@ -793,7 +793,7 @@
                               const std::vector<BackendId>& backendPreferences,
                               const IDeviceSpec& deviceSpec,
                               const OptimizerOptions& options,
-                              Optional<std::vector<std::string>&> errMessages)
+                              Optional<std::vector<std::string>&> messages)
 {
     if (backendPreferences.empty())
     {
@@ -837,7 +837,7 @@
         std::stringstream failureMsg;
         failureMsg << "None of the preferred backends " << backendPreferences
                    << " are supported. Current platform provides " << backendSettings.m_SupportedBackends;
-        ReportError(failureMsg.str(), errMessages);
+        ReportError(failureMsg.str(), messages);
         return IOptimizedNetworkPtr(nullptr, &IOptimizedNetwork::Destroy);
     }
 
@@ -852,7 +852,7 @@
                                                              backendSettings,
                                                              firstLayer,
                                                              lastLayer,
-                                                             errMessages);
+                                                             messages);
     if (assignBackendsResult.m_Error)
     {
         // Failed to assign a backend to each layer
@@ -866,7 +866,7 @@
     OptimizationResult backendOptimizationResult = ApplyBackendOptimizations(optNetObjPtr,
                                                                              backendSettings,
                                                                              backends,
-                                                                             errMessages);
+                                                                             messages);
     if (backendOptimizationResult.m_Error)
     {
         // Failed to apply the backend-specific optimizations
@@ -884,7 +884,7 @@
     OptimizationResult strategyResult = SelectTensorHandleStrategy(optGraph,
                                                                    backends,
                                                                    tensorHandleFactoryRegistry,
-                                                                   errMessages);
+                                                                   messages);
     if (strategyResult.m_Error)
     {
         // Failed to apply the backend-specific optimizations