Resolver: Handle AccessControl for storage-class propagation

Fix msl tests that were impacted by this

Change-Id: I00f4280c2f059358d9187babda9e44f2d16b096e
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/45244
Commit-Queue: Ben Clayton <bclayton@google.com>
Reviewed-by: David Neto <dneto@google.com>
diff --git a/src/resolver/resolver.cc b/src/resolver/resolver.cc
index a412be2..5d6b756 100644
--- a/src/resolver/resolver.cc
+++ b/src/resolver/resolver.cc
@@ -1500,7 +1500,7 @@
 
 bool Resolver::ApplyStorageClassUsageToType(ast::StorageClass sc,
                                             type::Type* ty) {
-  ty = ty->UnwrapAliasIfNeeded();
+  ty = ty->UnwrapIfNeeded();
 
   if (auto* str = ty->As<type::Struct>()) {
     auto* info = Structure(str);
diff --git a/src/writer/msl/generator_impl_function_test.cc b/src/writer/msl/generator_impl_function_test.cc
index fc8c55d..8c67520 100644
--- a/src/writer/msl/generator_impl_function_test.cc
+++ b/src/writer/msl/generator_impl_function_test.cc
@@ -275,8 +275,8 @@
 
 using namespace metal;
 struct Data {
-  int a;
-  float b;
+  /* 0x0000 */ int a;
+  /* 0x0004 */ float b;
 };
 
 fragment void frag_main(device Data& coord [[buffer(0)]]) {
@@ -319,8 +319,8 @@
 
 using namespace metal;
 struct Data {
-  int a;
-  float b;
+  /* 0x0000 */ int a;
+  /* 0x0004 */ float b;
 };
 
 fragment void frag_main(const device Data& coord [[buffer(0)]]) {
@@ -591,8 +591,8 @@
 
 using namespace metal;
 struct Data {
-  int a;
-  float b;
+  /* 0x0000 */ int a;
+  /* 0x0004 */ float b;
 };
 
 float sub_func(device Data& coord, float param) {
@@ -650,8 +650,8 @@
 
 using namespace metal;
 struct Data {
-  int a;
-  float b;
+  /* 0x0000 */ int a;
+  /* 0x0004 */ float b;
 };
 
 float sub_func(const device Data& coord, float param) {
@@ -794,7 +794,7 @@
 
 using namespace metal;
 struct Data {
-  float d;
+  /* 0x0000 */ float d;
 };
 
 kernel void a(device Data& data [[buffer(0)]]) {