#22 closed defect (fixed)
Basic types in forall/trait allowed
Reported by: | pabuhr | Owned by: | pabuhr |
---|---|---|---|
Priority: | major | Component: | cfa-cc |
Version: | 1.0 | Keywords: | |
Cc: |
Description
Are either of these allowed?
forall( int T ) g() {} trait X(int T) { int h(); };
If not, they need a better error message:
cfa test.c CFA Version 1.0.0 (debug) *CFA assertion error* "false" from program "cfa-cpp" in "void buildList(const NodeType*, Container<SynTreeType*, Args ...>&) [with SynTreeType = TypeDecl; NodeType = DeclarationNode; Container = std::__cxx11::list; Args = {std::allocator<TypeDecl*>}]" at line 424 in file "Parser/ParseNode.h": buildList unknown type Stack back trace for: /u/pabuhr/software/cfa-cc/lib/cfa/cfa-cpp (0) /u/pabuhr/software/cfa-cc/lib/cfa/cfa-cpp : void buildList<TypeDecl, DeclarationNode, std::__cxx11::list, std::allocator<TypeDecl*> >(DeclarationNode const*, std::__cxx11::list<TypeDecl*, std::allocator<TypeDecl*> >&)+0xce [0x5a7ede] (1) /u/pabuhr/software/cfa-cc/lib/cfa/cfa-cpp : void buildForall<std::__cxx11::list<TypeDecl*, std::allocator<TypeDecl*> > >(DeclarationNode const*, std::__cxx11::list<TypeDecl*, std::allocator<TypeDecl*> >&)+0x32 [0x5a7ff2] (2) /u/pabuhr/software/cfa-cc/lib/cfa/cfa-cpp : buildFunction(TypeData const*)+0xde [0x5a7a5e] (3) /u/pabuhr/software/cfa-cc/lib/cfa/cfa-cpp : buildDecl(TypeData const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, Type::StorageClasses, Expression*, Type::FuncSpecifiers, LinkageSpec::Spec, ConstantExpr*, Initializer*, std::__cxx11::list<Attribute*, std::allocator<Attribute*> >)+0x1cc [0x5a768c] (4) /u/pabuhr/software/cfa-cc/lib/cfa/cfa-cpp : DeclarationNode::build() const+0x2bf [0x59688f] (5) /u/pabuhr/software/cfa-cc/lib/cfa/cfa-cpp : buildList(DeclarationNode const*, std::__cxx11::list<Declaration*, std::allocator<Declaration*> >&)+0xba [0x5973aa] (6) /u/pabuhr/software/cfa-cc/lib/cfa/cfa-cpp : main(/*unknown*/)+0x492 [0x4b0712]
Change History (4)
comment:1 Changed 5 years ago by
Owner: | set to pabuhr |
---|---|
Status: | new → assigned |
comment:2 Changed 5 years ago by
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Note: See
TracTickets for help on using
tickets.
In 3e274ab: