Fix: multidimensional fixed-size arrays (NDK/CPP)

T[N][M] should be mapped to array<array<T,M>,N>.

C++'s ConstantValueDecorator is modified as well to support default
values for multidimensional fixed-size arrays. To initialize nested
arrays, we need double braces like:
  array<array<int, 3>,2> ints = {{ {{ 1,2,3 }}, {{4,5,6}} }};

Bug: 207087196
Test: golden_test.sh check
Test: aidl_integration_test
Change-Id: Ice95843f68df3ab86d85c208d4b2ba745f3a0a56
diff --git a/aidl_language.h b/aidl_language.h
index 35a0215..7d8f625 100644
--- a/aidl_language.h
+++ b/aidl_language.h
@@ -404,6 +404,8 @@
   // View of this type which has one-less dimension(s).
   // e.g.) T[] => T, T[N][M] => T[M]
   void ViewAsArrayBase(std::function<void(const AidlTypeSpecifier&)> func) const;
+  // ViewAsArrayBase passes "mutated" type to its callback.
+  bool IsMutated() const { return mutated_; }
 
   // Returns the full-qualified name of the base type.
   // int -> int
@@ -443,6 +445,7 @@
   bool IsFixedSizeArray() const {
     return array_.has_value() && std::get_if<FixedSizeArray>(&*array_) != nullptr;
   }
+  std::vector<int32_t> GetFixedSizeArrayDimensions() const;
 
   const ArrayType& GetArray() const {
     AIDL_FATAL_IF(!array_.has_value(), this) << "GetArray() for non-array type";
@@ -471,6 +474,8 @@
   const string unresolved_name_;
   string fully_qualified_name_;
   mutable std::optional<ArrayType> array_;
+  mutable bool mutated_ = false;  // ViewAsArrayBase() sets this as true to distinguish mutated one
+                                  // from the original type
   vector<string> split_name_;
   const AidlDefinedType* defined_type_ = nullptr;  // set when Resolve() for defined types
 };