mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-23 22:52:11 +02:00
Bug 410519 - UnsupportedOperationException: addMember method should be
called instead.
This commit is contained in:
parent
7053a577c3
commit
83c3e6d27f
1 changed files with 5 additions and 4 deletions
|
@ -1,5 +1,5 @@
|
||||||
/*******************************************************************************
|
/*******************************************************************************
|
||||||
* Copyright (c) 2005, 2012 IBM Corporation and others.
|
* Copyright (c) 2005, 2013 IBM Corporation and others.
|
||||||
* All rights reserved. This program and the accompanying materials
|
* All rights reserved. This program and the accompanying materials
|
||||||
* are made available under the terms of the Eclipse Public License v1.0
|
* are made available under the terms of the Eclipse Public License v1.0
|
||||||
* which accompanies this distribution, and is available at
|
* which accompanies this distribution, and is available at
|
||||||
|
@ -107,10 +107,11 @@ public class AbstractCPPClassSpecializationScope implements ICPPClassSpecializat
|
||||||
if (classScope == null)
|
if (classScope == null)
|
||||||
return IBinding.EMPTY_BINDING_ARRAY;
|
return IBinding.EMPTY_BINDING_ARRAY;
|
||||||
|
|
||||||
IBinding[] bindings= classScope.getBindings(lookup);
|
IBinding[] bindings= classScope.getBindings(lookup);
|
||||||
IBinding[] result= null;
|
IBinding[] result= null;
|
||||||
for (IBinding binding : bindings) {
|
for (IBinding binding : bindings) {
|
||||||
if (binding == specialized) {
|
if (binding == specialized ||
|
||||||
|
(binding instanceof ICPPClassType && specialized.isSameType((IType) binding))) {
|
||||||
binding= specialClass;
|
binding= specialClass;
|
||||||
} else {
|
} else {
|
||||||
binding= specialClass.specializeMember(binding, lookup.getLookupPoint());
|
binding= specialClass.specializeMember(binding, lookup.getLookupPoint());
|
||||||
|
|
Loading…
Add table
Reference in a new issue