Problem with ObjC's type-encoding of nested structs causing infinit recursion.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@46260 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/test/Sema/objc-encoding-bug-1.m b/test/Sema/objc-encoding-bug-1.m
new file mode 100644
index 0000000..ecf7d81
--- /dev/null
+++ b/test/Sema/objc-encoding-bug-1.m
@@ -0,0 +1,19 @@
+// RUN: clang -rewrite-test %s | clang
+
+typedef struct NSMethodFrameArgInfo {
+    struct NSMethodFrameArgInfo *subInfo;
+    struct NSMethodFrameArgInfo *an;
+} NSMethodFrameArgInfo;
+
+@interface NSMethodSignature 
+- (NSMethodFrameArgInfo *)_argInfo;
+@end
+
+@implementation NSMethodSignature
+
+- (NSMethodFrameArgInfo *)_argInfo{
+    return 0;
+}
+
+@end
+