From ce2952bb799ea3830acd2c7794a6d903227df69c Mon Sep 17 00:00:00 2001 From: David Engster Date: Fri, 2 Aug 2013 21:46:42 +0200 Subject: [PATCH] Revert rev. 6995 (semantic-analyze-find-tag-sequence-default): Always add scope to the local miniscope for each type. Otherwise, structure tags are not analyzed correctly. Also, always search the extended miniscope even when not dealing with types. * tests/cedet/semantic/test/manual/cedet/testdoublens.cpp: Add test case for the above change. --- .../cedet/semantic/tests/testdoublens.cpp | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/test/manual/cedet/cedet/semantic/tests/testdoublens.cpp b/test/manual/cedet/cedet/semantic/tests/testdoublens.cpp index e9fc5bca7d7..f4624724df8 100644 --- a/test/manual/cedet/cedet/semantic/tests/testdoublens.cpp +++ b/test/manual/cedet/cedet/semantic/tests/testdoublens.cpp @@ -162,3 +162,21 @@ void someFunc(const struct ContainsStruct::TheStruct *foo) foo->// -9- // #9# ("memberOne" "memberTwo") } + +// Class with structure tag +class ContainsNamedStruct +{ + struct _fooStruct + { + int memberOne; + int memberTwo; + } member; +}; + +void someOtherFunc(void) +{ + ContainsNamedStruct *someClass; + // This has to find ContainsNamedStruct::_fooStruct + someClass->member.// -10- + // #10# ("memberOne" "memberTwo") +} -- 2.39.5