public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "nheghathivhistha at gmail dot com" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug other/59882] dev-cpp/xsd: internal compiler error: Segmentation fault Date: Mon, 20 Jan 2014 02:20:00 -0000 [thread overview] Message-ID: <bug-59882-4-qBsk7wSuXa@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-59882-4@http.gcc.gnu.org/bugzilla/> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59882 --- Comment #2 from David Kredba <nheghathivhistha at gmail dot com> --- c-reduce at --sllooww> namespace std { template < class, class > struct pair; template < typename _Iterator > struct iterator_traits { typedef typename _Iterator::value_type value_type; }; template < typename > class allocator { public: template < typename > struct rebind { typedef allocator other; }; }; template < typename > struct less { }; template < typename > struct _Select1st; } namespace __gnu_cxx { template < typename _Alloc > struct __alloc_traits { template < typename _Tp > struct rebind { typedef typename _Alloc::template rebind < _Tp >::other other; }; }; } namespace std { template < typename > struct _Rb_tree_node; template < typename, typename _Val, typename, typename _Compare, typename _Alloc = allocator < _Val > >class _Rb_tree { typedef typename __gnu_cxx::__alloc_traits < _Alloc >::template rebind < _Rb_tree_node < _Val > >::other _Node_allocator; typedef _Alloc allocator_type; template < typename _Key_compare > struct _Rb_tree_impl { _Rb_tree_impl (_Key_compare, _Node_allocator); }; _Rb_tree_impl < _Compare > _M_impl; public: _Rb_tree (_Compare __comp, allocator_type __a):_M_impl (__comp, __a) { } }; template < typename _Key, typename _Tp, typename _Compare = less < _Key >, typename _Alloc = allocator < pair < _Key, _Tp > > >class map { public: typedef _Key key_type; typedef pair < _Key, _Tp > value_type; typedef _Compare key_compare; typedef _Alloc allocator_type; typedef _Rb_tree < key_type, value_type, _Select1st < value_type >, key_compare > _Rep_type; _Rep_type _M_t; map (_Compare __comp, allocator_type __a = allocator_type ()):_M_t (__comp, __a) { } }; template < typename _Tp > struct _List_iterator { typedef _Tp value_type; }; template < typename _Tp > class list { public: typedef _List_iterator < _Tp > iterator; }; } namespace Cult { namespace Types { namespace Fundamental { typedef void Void; typedef int WideChar; } using Fundamental::Void; using Fundamental::WideChar; } namespace { template < typename I > class IteratorAdapter { public: typedef typename std::iterator_traits < I >::value_type Value; }; } namespace Types { template < typename > class StringTemplate; typedef StringTemplate < WideChar > WideString; } namespace Containers { template < typename K, typename T > class Map:std::map < K, T > { typedef std::map < K, T > Base; typedef typename Base::key_compare Compare; public: Map (Compare comp = Compare ()):Base (comp) { } }; template < typename T > class List { typedef std::list < T > Base; public: typedef IteratorAdapter < typename Base::iterator > Iterator; }; } } namespace { using namespace Cult::Types; } namespace XSDFrontend { namespace SemanticGraph { namespace Bits { template < typename > struct strip_pointer; template < typename X > struct strip_pointer <X * > { typedef X Type; }; template < typename I > struct PointerIterator { typedef typename strip_pointer < typename I::Value >::Type Reference; Reference operator* (); }; } class Edge { }; class Node; class Names:public Edge { }; class Scope { typedef Cult::Containers::List < Names * >NamesList; public: typedef Bits::PointerIterator < NamesList::Iterator > NamesIterator; }; class Type; class Complex:public Scope { }; } } namespace FrontendElements { namespace Traversal { template < typename > class TraverserBase { }; template < typename X > class DispatcherBase { public: virtual Void dispatch (X); }; template < typename X > class Dispatcher:public DispatcherBase < X > { }; } } namespace XSDFrontend { namespace Traversal { namespace Bits { using FrontendElements::Traversal::TraverserBase; using FrontendElements::Traversal::DispatcherBase; using FrontendElements::Traversal::Dispatcher; } typedef Bits::DispatcherBase < SemanticGraph::Edge > EdgeDispatcherBase; struct EdgeBase:virtual Bits::Dispatcher < SemanticGraph::Edge >, Bits::Dispatcher < SemanticGraph::Node > { }; template < typename > struct Edge:Bits::TraverserBase < SemanticGraph::Edge >, EdgeBase { }; struct Names:Edge < Names > { }; template < typename T > struct ScopeTemplate { template < typename > Void names (T, EdgeDispatcherBase & d) { typename T::NamesIterator b; d.dispatch (*b); } Void names (T s, EdgeDispatcherBase & d) { names < ScopeTemplate > (s, d); } }; struct Complex:ScopeTemplate < SemanticGraph::Complex > { }; } typedef WideString String; class Context { }; namespace Parser { namespace { typedef Cult::Containers::Map < SemanticGraph::Type, String > TypeInstanceMap; struct BaseType { BaseType (Context); }; struct ArgList:Traversal::Complex { ArgList (Context, TypeInstanceMap) { } virtual Void traverse (SemanticGraph::Complex c) { names (c, names_); } TypeInstanceMap map_; Traversal::Names names_; }; struct ParserConnect:Context { ParserConnect (Context c, TypeInstanceMap):base_ (c) { ArgList (*this, map_); } TypeInstanceMap map_; BaseType base_; }; } Void generate_driver_source (Context ctx) { TypeInstanceMap map; ParserConnect (ctx, map); } } }
next prev parent reply other threads:[~2014-01-20 2:20 UTC|newest] Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top 2014-01-19 17:27 [Bug other/59882] New: " nheghathivhistha at gmail dot com 2014-01-19 22:27 ` [Bug other/59882] " nheghathivhistha at gmail dot com 2014-01-20 2:20 ` nheghathivhistha at gmail dot com [this message] 2014-01-20 6:38 ` [Bug ipa/59882] [4.9 Regression] " trippels at gcc dot gnu.org 2014-01-20 9:36 ` rguenth at gcc dot gnu.org 2014-02-03 22:00 ` hubicka at gcc dot gnu.org 2014-02-04 6:28 ` hubicka at gcc dot gnu.org 2014-02-04 6:32 ` hubicka at gcc dot gnu.org
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=bug-59882-4-qBsk7wSuXa@http.gcc.gnu.org/bugzilla/ \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).