Commit bd4373fc authored by david_v's avatar david_v
Browse files

from Valentin David <valentin@lrde.epita.fr>

	* src/disamb/disambiguate/UsingDefinition.str,
	* src/disamb/disambiguate/UsingDefinition.meta: New.
	* src/disamb/disambiguate/Definition.str: Handle using declarations.

	* src/disamb/disambiguate/Makefile.am: Update.

	* src/disamb/disambiguate/NamespaceDefinition.str: Use getkey.

	* src/disamb/disambiguate/CheckNamespaceName.str,
	* src/disamb/disambiguate/CheckClassName.str: Use scopes.

	* src/disamb/disambiguate/GetKey.str:
	Add rules for namespaces. Fix bugs on alias

	* src/disamb/disambiguate/EnumDefinitionCandidate.str,
	* src/disamb/disambiguate/EnumDefinition.str: Check only named enums.

	* src/disamb/disambiguate/DeclaratorIdAmbiguity.str: Correct a mistake.

	* src/disamb/disambiguate/ClassOrNamespaceTraverse.str:
	Check if the class or the namespace exists.

	* test/disambiguate/Makefile.am (XFAIL_TESTS): Update.

2004-04-05  Valentin David  <valentin@lrde.epita.fr>
parent 88100c11
2004-04-05 Valentin David <valentin@lrde.epita.fr>
* src/disamb/disambiguate/UsingDefinition.str,
* src/disamb/disambiguate/UsingDefinition.meta: New.
* src/disamb/disambiguate/Definition.str: Handle using declarations.
* src/disamb/disambiguate/Makefile.am: Update.
* src/disamb/disambiguate/NamespaceDefinition.str: Use getkey.
* src/disamb/disambiguate/CheckNamespaceName.str,
* src/disamb/disambiguate/CheckClassName.str: Use scopes.
* src/disamb/disambiguate/GetKey.str:
Add rules for namespaces. Fix bugs on alias
* src/disamb/disambiguate/EnumDefinitionCandidate.str,
* src/disamb/disambiguate/EnumDefinition.str: Check only named enums.
* src/disamb/disambiguate/DeclaratorIdAmbiguity.str: Correct a mistake.
* src/disamb/disambiguate/ClassOrNamespaceTraverse.str:
Check if the class or the namespace exists.
* test/disambiguate/Makefile.am (XFAIL_TESTS): Update.
2004-04-05 Valentin David <valentin@lrde.epita.fr> 2004-04-05 Valentin David <valentin@lrde.epita.fr>
* src/strcxxgen/strcxxgen.str: Fix variable name productions. * src/strcxxgen/strcxxgen.str: Fix variable name productions.
......
/* /*
* Copyright (C) 2003 EPITA Research and Development Laboratory * Copyright (C) 2003, 2004 EPITA Research and Development Laboratory
* *
* This program is free software; you can redistribute it and/or modify * This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by * it under the terms of the GNU General Public License as published by
...@@ -41,14 +41,15 @@ rules ...@@ -41,14 +41,15 @@ rules
CheckClassName : |ClassOrNamespaceName[ ClassName ]| -> |ClassOrNamespaceName[ ClassName' ]| CheckClassName : |ClassOrNamespaceName[ ClassName ]| -> |ClassOrNamespaceName[ ClassName' ]|
where < CheckClassName > ClassName => ClassName' where < CheckClassName > ClassName => ClassName'
//FIXME: nested-name-specifier
CheckClassName : |MemInitializerId[ Dummy0-opt la1 NestedNameSpecifier-opt la2 ClassName ]| -> |MemInitializerId[ Dummy0-opt la1 NestedNameSpecifier-opt la2 ClassName' ]| CheckClassName : |MemInitializerId[ Dummy0-opt la1 NestedNameSpecifier-opt la2 ClassName ]| -> |MemInitializerId[ Dummy0-opt la1 NestedNameSpecifier-opt la2 ClassName' ]|
where < CheckClassName > ClassName => ClassName' where < CheckClassName > ClassName => ClassName'
CheckClassName : a@|ClassName[ ID ]| -> a CheckClassName : a@|ClassName[ ID ]| -> a
where < identifier > ID => c where < identifier > ID => c
; < rewrite (!"$namespace") > "$value" => d ; < rewrite (!"$namespace") > "$value" => d
; (< lookup > c => class-kind ; (< scope(!"$namespace", lookup) > c => class-kind
<+ < lookup > c => type-kind) // Bugfix for Std C++ grammar <+ < scope(!"$namespace", lookup) > c => type-kind) // Bugfix for Std C++ grammar
; < print-key > d => e ; < print-key > d => e
; < concat-strings ; ifdebug (debug) > ["Resolved ambiguity on name", " ", c, " ", ; < concat-strings ; ifdebug (debug) > ["Resolved ambiguity on name", " ", c, " ",
"in namespace", " ", e, " ", "in namespace", " ", e, " ",
...@@ -57,7 +58,7 @@ rules ...@@ -57,7 +58,7 @@ rules
CheckClassName : |ClassName[ ~TemplateId: tid@|TemplateId[ID < TemplateArgumentList-opt > ]|~ ]| -> |ClassName[ ~TemplateId: tid'~ ]| CheckClassName : |ClassName[ ~TemplateId: tid@|TemplateId[ID < TemplateArgumentList-opt > ]|~ ]| -> |ClassName[ ~TemplateId: tid'~ ]|
where < identifier > ID => c where < identifier > ID => c
; < rewrite (!"$namespace") > "$value" => d ; < rewrite (!"$namespace") > "$value" => d
; < lookup > c => class-template-kind([_]) ; < scope(!"$namespace", lookup) > c => class-template-kind([_])
; < print-key > d => e ; < print-key > d => e
; < resolve > tid => tid' ; < resolve > tid => tid'
; < concat-strings ; ifdebug (debug) > ["Resolved ambiguity on name", " ", c, " ", ; < concat-strings ; ifdebug (debug) > ["Resolved ambiguity on name", " ", c, " ",
......
...@@ -37,7 +37,7 @@ rules ...@@ -37,7 +37,7 @@ rules
CheckNamespaceOriginalName : a@|NamespaceName[ ~OriginalNamespaceName: |OriginalNamespaceName[ ID ]|~ ]| -> a CheckNamespaceOriginalName : a@|NamespaceName[ ~OriginalNamespaceName: |OriginalNamespaceName[ ID ]|~ ]| -> a
where < identifier > ID => c where < identifier > ID => c
; < rewrite (!"$namespace") > "$value" => d ; < rewrite (!"$namespace") > "$value" => d
; < lookup > c => namespace-kind ; < scope(!"$namespace", lookup) > c => namespace-kind
; < print-key > d => e ; < print-key > d => e
; < concat-strings ; ifdebug (debug) > ["Resolved ambiguity on name", " ", c, " ", ; < concat-strings ; ifdebug (debug) > ["Resolved ambiguity on name", " ", c, " ",
"in namespace", " ", e, " ", "in namespace", " ", e, " ",
...@@ -46,7 +46,7 @@ rules ...@@ -46,7 +46,7 @@ rules
CheckNamespaceAliasName : a@|NamespaceName[ ~NamespaceAlias: |NamespaceAlias[ ID ]|~ ]| -> a CheckNamespaceAliasName : a@|NamespaceName[ ~NamespaceAlias: |NamespaceAlias[ ID ]|~ ]| -> a
where < identifier > ID => c where < identifier > ID => c
; < rewrite (!"$namespace") > "$value" => d ; < rewrite (!"$namespace") > "$value" => d
; < lookup > c => alias-kind ; < scope(!"$namespace", lookup) > c => alias-kind
; < print-key > d => e ; < print-key > d => e
; < concat-strings ; ifdebug (debug) > ["Resolved ambiguity on name", " ", c, " ", ; < concat-strings ; ifdebug (debug) > ["Resolved ambiguity on name", " ", c, " ",
"in namespace", " ", e, " ", "in namespace", " ", e, " ",
......
...@@ -36,9 +36,18 @@ rules ...@@ -36,9 +36,18 @@ rules
where < oncetd(?|Identifier[ ID ]|); !ID; identifier > nsn => c where < oncetd(?|Identifier[ ID ]|); !ID; identifier > nsn => c
; < rewrite (!"$namespace") > "$value" => d ; < rewrite (!"$namespace") > "$value" => d
; < ?list-key (as); !as > d => d' ; < ?list-key (as); !as > d => d'
; < conc; ?x; !list-key (x) > (d', [string-key (c)]) => e ; < conc; ?x; !list-key (x) > (d', [string-key (c)])
; < print-key > e => e' ; try(get-alias)
; < concat-strings ; ifdebug (debug) > ["Following nested name resolution to namespace", " ", e'] ; list-key(at-last([string-key(?name)]; ![])) => path
; scope(!"$namespace",
< assert (!"$namespace") >
("$value", path)
; <lookup> name
; (namespace-kind <+ alias-kind)
; < rewrite (!"$namespace") > "$value"
; list-key(<concat> [<id>, [string-key(name)]]) => e)
; print-key
; < concat-strings ; ifdebug (debug) > ["Following nested name resolution to namespace", " ", <id>]
; < assert (!"$namespace") > ("$value", e) ; < assert (!"$namespace") > ("$value", e)
ClassOrNamespaceTraverse-1 : a@|ClassOrNamespaceName[ ClassOrNamespaceTraverse-1 : a@|ClassOrNamespaceName[
...@@ -48,8 +57,16 @@ rules ...@@ -48,8 +57,16 @@ rules
; < ?list-key (as); !as > d => d' ; < ?list-key (as); !as > d => d'
; < conc; ?x; !list-key (x) > (d', [string-key (c)]) ; < conc; ?x; !list-key (x) > (d', [string-key (c)])
; try(get-alias) => e ; try(get-alias) => e
; < print-key > e => e' ; list-key(at-last([string-key(?name)]; ![])) => path
; < concat-strings ; ifdebug (debug) > ["Following nested name resolution to class", " ", e'] ; scope(!"$namespace",
< assert (!"$namespace") >
("$value", path)
; <lookup> name
; class-kind
; < rewrite (!"$namespace")> "$value"
; list-key(<concat> [<id>, [string-key(name)]]) => e)
; print-key
; < concat-strings ; ifdebug (debug) > ["Following nested name resolution to class", " ", <id>]
; < assert (!"$namespace") > ("$value", e) ; < assert (!"$namespace") > ("$value", e)
ClassOrNamespaceTraverse-2 : a@|ClassOrNamespaceName[ ClassOrNamespaceTraverse-2 : a@|ClassOrNamespaceName[
...@@ -58,15 +75,18 @@ rules ...@@ -58,15 +75,18 @@ rules
-> a -> a
where < identifier > ID => c where < identifier > ID => c
; < rewrite (!"$namespace") > "$value" => d ; < rewrite (!"$namespace") > "$value" => d
; < scope (!"$namespace", lookup) > c => class-template-kind (l) ; scope (!"$namespace",
<lookup> c => class-template-kind (l)
; < template-arguments-resolve(!l) > TemplateArgumentList-opt => TemplateArgumentList-opt' ; < template-arguments-resolve(!l) > TemplateArgumentList-opt => TemplateArgumentList-opt'
; < template-arguments > TemplateArgumentList-opt => g ; < template-arguments > TemplateArgumentList-opt => g
; < rewrite (!"$namespace") > "$value"
; list-key(<concat> [<id>, [template-key(c,g)]]) => p)
; < id > template-key (c, g) => f ; < id > template-key (c, g) => f
; < ?list-key (as); !as > d => d' ; < ?list-key (as); !as > d => d'
; < conc; ?x; !list-key (x) > (d', [f]) => e ; < conc; ?x; !list-key (x) > (d', [f]) => e
; < print-key > e => e' ; < print-key > p => e'
; < concat-strings ; ifdebug (debug) > ["Following nested name resolution to class-template", " ", e'] ; < concat-strings ; ifdebug (debug) > ["Following nested name resolution to class-template", " ", e']
; < assert (!"$namespace") > ("$value", e) ; < assert (!"$namespace") > ("$value", p)
strategies strategies
......
...@@ -37,7 +37,7 @@ strategies ...@@ -37,7 +37,7 @@ strategies
TypeName ]|} TypeName ]|}
) )
) )
; where (< ifdebug (debug) > "Candidate for declarator id ambituity") ; where (< ifdebug (debug) > "Candidate for declarator id ambiguity")
declarator-id-ambiguity-stop(s) = declarator-id-ambiguity-candidate declarator-id-ambiguity-stop(s) = declarator-id-ambiguity-candidate
......
...@@ -35,6 +35,7 @@ imports ...@@ -35,6 +35,7 @@ imports
EnumDefinition EnumDefinition
TemplateFunctionDefinition TemplateFunctionDefinition
ConstructorDefinition ConstructorDefinition
UsingDefinition
strategies strategies
...@@ -46,6 +47,7 @@ strategies ...@@ -46,6 +47,7 @@ strategies
class-definition-stop(s) <+ class-definition-stop(s) <+
enum-definition-stop(s) <+ enum-definition-stop(s) <+
type-definition-stop(s) <+ type-definition-stop(s) <+
using-definition-stop(s) <+
constructor-definition-stop(s) <+ constructor-definition-stop(s) <+
compound-statement-candidate compound-statement-candidate
...@@ -56,6 +58,7 @@ strategies ...@@ -56,6 +58,7 @@ strategies
class-definition <+ class-definition <+
enum-definition <+ enum-definition <+
type-definition <+ type-definition <+
using-definition <+
constructor-definition <+ constructor-definition <+
variable-definition <+ variable-definition <+
not (namespace-definition-candidate <+ not (namespace-definition-candidate <+
...@@ -65,6 +68,7 @@ strategies ...@@ -65,6 +68,7 @@ strategies
class-definition-candidate <+ class-definition-candidate <+
enum-definition-candidate <+ enum-definition-candidate <+
type-definition-candidate <+ type-definition-candidate <+
using-definition-candidate <+
variable-definition-candidate) variable-definition-candidate)
definition = topdownS (definition-single, definition = topdownS (definition-single,
......
/* /*
* Copyright (C) 2003 EPITA Research and Development Laboratory * Copyright (C) 2003, 2004 EPITA Research and Development Laboratory
* *
* This program is free software; you can redistribute it and/or modify * This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by * it under the terms of the GNU General Public License as published by
...@@ -34,8 +34,8 @@ imports ...@@ -34,8 +34,8 @@ imports
rules rules
EnumDefinition : a@|EnumSpecifier[ enum Identifier-opt { EnumeratorList } ]| -> a EnumDefinition : a@|EnumSpecifier[ enum ID { EnumeratorList-opt } ]| -> a
where < ?|Identifier?[ ID ]|; !ID; identifier > Identifier-opt => c where < identifier > ID => c
; < rewrite (!"$namespace") > "$value" => d ; < rewrite (!"$namespace") > "$value" => d
; < assert (!d) > (c, enum-kind) ; < assert (!d) > (c, enum-kind)
; < ?list-key (as); !as > d => d' ; < ?list-key (as); !as > d => d'
......
/* /*
* Copyright (C) 2003 EPITA Research and Development Laboratory * Copyright (C) 2003, 2004 EPITA Research and Development Laboratory
* *
* This program is free software; you can redistribute it and/or modify * This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by * it under the terms of the GNU General Public License as published by
...@@ -34,7 +34,7 @@ imports ...@@ -34,7 +34,7 @@ imports
rules rules
EnumDefinitionCandidate : a@|EnumSpecifier[ enum Identifier-opt { EnumeratorList } ]| -> a EnumDefinitionCandidate : a@|EnumSpecifier[ enum ID { EnumeratorList-opt } ]| -> a
where < ifdebug (debug) > "Candidate for enum definition" where < ifdebug (debug) > "Candidate for enum definition"
strategies strategies
......
...@@ -36,13 +36,28 @@ signature ...@@ -36,13 +36,28 @@ signature
rules rules
Namespace-GetKey : |NamespaceName[ ~OriginalNamespaceName: |OriginalNamespaceName[ ID ]|~ ]| -> key
where < identifier > ID => c
; < rewrite (!"$namespace") > "$value" => d
; !list-key([string-key(c)])
; < ?list-key(a) > d
; !list-key(<conc>(a, [string-key(c)])) => key
Namespace-GetKey : |NamespaceName[ ~NamespaceAlias: |NamespaceAlias[ ID ]|~ ]| -> key
where < identifier > ID => c
; < rewrite (!"$namespace") > "$value" => d
; < get-alias > c
; < ?(list-key(a), list-key(b)) > (d, <id>)
; !list-key(<conc>(a, b)) => key
TypeName-GetKey : |TypeName[ ~ClassName: |ClassName[ ID ]|~ ]| -> key TypeName-GetKey : |TypeName[ ~ClassName: |ClassName[ ID ]|~ ]| -> key
where < identifier > ID => c where < identifier > ID => c
; < rewrite (!"$namespace") > "$value" => d ; < rewrite (!"$namespace") > "$value" => d
; ( < scope(!"$namespace", lookup) > c => class-kind ; ( < scope(!"$namespace", lookup) > c => class-kind
; !list-key([string-key(c)]) ; !list-key([string-key(c)])
<+ < scope(!"$namespace", lookup) > c => type-kind <+ < scope(!"$namespace", lookup) > c => type-kind
; < get-alias > c) ; ( < get-alias > c
<+!list-key([string-key(c)])))
; < ?(list-key(a), list-key(b)) > (d, <id>) ; < ?(list-key(a), list-key(b)) > (d, <id>)
; !list-key(<conc>(a, b)) => key ; !list-key(<conc>(a, b)) => key
...@@ -53,7 +68,8 @@ rules ...@@ -53,7 +68,8 @@ rules
; ( < scope(!"$namespace", lookup) > c => class-template-kind(_) ; ( < scope(!"$namespace", lookup) > c => class-template-kind(_)
; !list-key([template-key(c,g)]) ; !list-key([template-key(c,g)])
<+ < scope(!"$namespace", lookup) > c => type-kind <+ < scope(!"$namespace", lookup) > c => type-kind
; < get-alias > c) ; ( < get-alias > c
<+!list-key([string-key(c)])))
; < ?(list-key(a), list-key(b)) > (d, <id>) ; < ?(list-key(a), list-key(b)) > (d, <id>)
; !list-key(<conc>(a, b)) => key ; !list-key(<conc>(a, b)) => key
...@@ -62,18 +78,30 @@ rules ...@@ -62,18 +78,30 @@ rules
where < identifier > ID => c where < identifier > ID => c
; < rewrite (!"$namespace") > "$value" => d ; < rewrite (!"$namespace") > "$value" => d
; < scope (!"$namespace", lookup) > c => type-kind ; < scope (!"$namespace", lookup) > c => type-kind
; < get-alias > c ; ( < get-alias > c
<+!list-key([string-key(c)]))
; < ?(list-key(a), list-key(b)) > (d, <id>) ; < ?(list-key(a), list-key(b)) > (d, <id>)
; !list-key(<conc>(a, b)) => key ; !list-key(<conc>(a, b)) => key
SimpleTypeSpecifier-GetKey : |SimpleTypeSpecifier[ Dummy0-opt NestedNameSpecifier-opt TypeName ]| -> key SimpleTypeSpecifier-GetKey : |SimpleTypeSpecifier[ Dummy0-opt NestedNameSpecifier-opt TypeName ]| -> key
where < local-or-global > Dummy0-opt where scope(!"$namespace",
< local-or-global > Dummy0-opt
; < try(
?|NestedNameSpecifier?[ ~NestedNameSpecifier: nested~ ]|;
!nested; nested-name-specifier; ?nested';
!|NestedNameSpecifier?[ ~NestedNameSpecifier: nested'~ ]|)
> NestedNameSpecifier-opt
; < TypeName-GetKey > TypeName => key)
QNamespace-GetKey : |QualifiedNamespaceSpecifier[ Dummy0-opt NestedNameSpecifier-opt NamespaceName ]| -> key
where scope(!"$namespace",
< local-or-global > Dummy0-opt
; < try( ; < try(
?|NestedNameSpecifier?[ ~NestedNameSpecifier: nested~ ]|; ?|NestedNameSpecifier?[ ~NestedNameSpecifier: nested~ ]|;
!nested; nested-name-specifier; ?nested'; !nested; nested-name-specifier; ?nested';
!|NestedNameSpecifier?[ ~NestedNameSpecifier: nested'~ ]|) !|NestedNameSpecifier?[ ~NestedNameSpecifier: nested'~ ]|)
> NestedNameSpecifier-opt > NestedNameSpecifier-opt
; < TypeName-GetKey > TypeName => key ; < Namespace-GetKey > NamespaceName => key)
strategies strategies
......
...@@ -71,6 +71,7 @@ SRCS = \ ...@@ -71,6 +71,7 @@ SRCS = \
TypeDeclaratorCandidate.str \ TypeDeclaratorCandidate.str \
TypeDefinition.str \ TypeDefinition.str \
TypeDefinitionCandidate.str \ TypeDefinitionCandidate.str \
UsingDefinition.str \
VariableDeclarator.str \ VariableDeclarator.str \
VariableDeclaratorCandidate.str \ VariableDeclaratorCandidate.str \
VariableDefinition.str \ VariableDefinition.str \
...@@ -134,6 +135,7 @@ METAS = \ ...@@ -134,6 +135,7 @@ METAS = \
TypeDeclaratorCandidate.meta \ TypeDeclaratorCandidate.meta \
TypeDefinition.meta \ TypeDefinition.meta \
TypeDefinitionCandidate.meta \ TypeDefinitionCandidate.meta \
UsingDefinition.meta \
VariableDeclarator.meta \ VariableDeclarator.meta \
VariableDeclaratorCandidate.meta \ VariableDeclaratorCandidate.meta \
VariableDefinition.meta \ VariableDefinition.meta \
......
...@@ -98,8 +98,7 @@ rules ...@@ -98,8 +98,7 @@ rules
; < rewrite (!"$namespace") > "$value" => d ; < rewrite (!"$namespace") > "$value" => d
; < try(namespace-name-ambiguity) > NamespaceName ; < try(namespace-name-ambiguity) > NamespaceName
=> NamespaceName' => NamespaceName'
; collect(?|Identifier[ ID' ]|) ; Namespace-GetKey => alias)
; !ID' => alias)
; < identifier > ID => c ; < identifier > ID => c
; < assert (!d) > (c, alias-kind) ; < assert (!d) > (c, alias-kind)
; < assert (!alias-table(d)) > (c, alias) ; < assert (!alias-table(d)) > (c, alias)
......
/*
* Copyright (C) 2004 EPITA Research and Development Laboratory
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
*/
module UsingDefinition
imports
lib
signature
constructors
assoc : Term -> Term
imports
AsFix2-Syntax
asfix
Cxx
Identifier
Kinds
rules
UsingDefinition: a@|UsingDeclaration[
using typename Dummy0-opt NestedNameSpecifier ID ; ]| -> a
where (<SimpleTypeSpecifier-GetKey> |SimpleTypeSpecifier[
Dummy0-opt NestedNameSpecifier ~TypedefName:
|TypedefName[ ID ]|~ ]|
<+ ![]) => alias
; <type-declarator(!alias)>
|DeclaratorId[ ~IdExpression:|IdExpression[ ID ]|~ ]|
UsingDefinition: a@|UsingDeclaration[
using Dummy0-opt NestedNameSpecifier ID ; ]| -> a
where try(<simple-type-specifier> |SimpleTypeSpecifier[
Dummy0-opt NestedNameSpecifier
~TypeName: amb([
|TypeName[ ~TypedefName:|TypedefName[ ID ]|~]|,
|TypeName[ ~ClassName:|ClassName[ ID ]|~]|,
|TypeName[ ~EnumName:|EnumName[ ID ]|~]|])~ ]|
; SimpleTypeSpecifier-GetKey => alias
; <type-declarator(!alias)> |DeclaratorId[ ~IdExpression:
|IdExpression[ ID ]|~ ]|)
UsingDefinition: a@|UsingDeclaration[ using :: ID ; ]| -> a
where try(<simple-type-specifier> |SimpleTypeSpecifier[
::
~TypeName: amb([
|TypeName[ ~TypedefName:|TypedefName[ ID ]|~]|,
|TypeName[ ~ClassName:|ClassName[ ID ]|~]|,
|TypeName[ ~EnumName:|EnumName[ ID ]|~]|])~ ]|
; SimpleTypeSpecifier-GetKey => alias
; <type-declarator(!alias)>
|DeclaratorId[ ~IdExpression:|IdExpression[ ID ]|~ ]|)
strategies
using-definition = using-definition-candidate; UsingDefinition
using-definition-candidate =
(?|UsingDeclaration[
using Dummy1-opt Dummy0-opt NestedNameSpecifier UnqualifiedId ; ]|
<+ ?|UsingDeclaration[ using :: UnqualifiedId' ; ]|)
; where(<ifdebug(debug)> "Candidate for using definition")
using-definition-stop(s) = using-definition-candidate
\ No newline at end of file
...@@ -84,10 +84,7 @@ TESTS = \ ...@@ -84,10 +84,7 @@ TESTS = \
variable-01 variable-01
XFAIL_TESTS = \ XFAIL_TESTS = \
namespace-08 \ namespace-10 \
namespace-09 \ template-12
namespace-10 \
namespace-11 \
template-12
EXTRA_DIST = test $(TESTS:=.cc) $(TESTS:=.detcc) EXTRA_DIST = test $(TESTS:=.cc) $(TESTS:=.detcc)
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment