100db7afdSDavid E. O'Brien// rb_tree extension -*- C++ -*-
200db7afdSDavid E. O'Brien
3*f8a1b7d9SAlexander Kabaev// Copyright (C) 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
400db7afdSDavid E. O'Brien//
500db7afdSDavid E. O'Brien// This file is part of the GNU ISO C++ Library.  This library is free
600db7afdSDavid E. O'Brien// software; you can redistribute it and/or modify it under the
700db7afdSDavid E. O'Brien// terms of the GNU General Public License as published by the
800db7afdSDavid E. O'Brien// Free Software Foundation; either version 2, or (at your option)
900db7afdSDavid E. O'Brien// any later version.
1000db7afdSDavid E. O'Brien
1100db7afdSDavid E. O'Brien// This library is distributed in the hope that it will be useful,
1200db7afdSDavid E. O'Brien// but WITHOUT ANY WARRANTY; without even the implied warranty of
1300db7afdSDavid E. O'Brien// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
1400db7afdSDavid E. O'Brien// GNU General Public License for more details.
1500db7afdSDavid E. O'Brien
1600db7afdSDavid E. O'Brien// You should have received a copy of the GNU General Public License along
1700db7afdSDavid E. O'Brien// with this library; see the file COPYING.  If not, write to the Free
18*f8a1b7d9SAlexander Kabaev// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
1900db7afdSDavid E. O'Brien// USA.
2000db7afdSDavid E. O'Brien
2100db7afdSDavid E. O'Brien// As a special exception, you may use this file as part of a free software
2200db7afdSDavid E. O'Brien// library without restriction.  Specifically, if other files instantiate
2300db7afdSDavid E. O'Brien// templates or use macros or inline functions from this file, or you compile
2400db7afdSDavid E. O'Brien// this file and link it with other files to produce an executable, this
2500db7afdSDavid E. O'Brien// file does not by itself cause the resulting executable to be covered by
2600db7afdSDavid E. O'Brien// the GNU General Public License.  This exception does not however
2700db7afdSDavid E. O'Brien// invalidate any other reasons why the executable file might be covered by
2800db7afdSDavid E. O'Brien// the GNU General Public License.
2900db7afdSDavid E. O'Brien
3000db7afdSDavid E. O'Brien/*
3100db7afdSDavid E. O'Brien *
3200db7afdSDavid E. O'Brien * Copyright (c) 1994
3300db7afdSDavid E. O'Brien * Hewlett-Packard Company
3400db7afdSDavid E. O'Brien *
3500db7afdSDavid E. O'Brien * Permission to use, copy, modify, distribute and sell this software
3600db7afdSDavid E. O'Brien * and its documentation for any purpose is hereby granted without fee,
3700db7afdSDavid E. O'Brien * provided that the above copyright notice appear in all copies and
3800db7afdSDavid E. O'Brien * that both that copyright notice and this permission notice appear
3900db7afdSDavid E. O'Brien * in supporting documentation.  Hewlett-Packard Company makes no
4000db7afdSDavid E. O'Brien * representations about the suitability of this software for any
4100db7afdSDavid E. O'Brien * purpose.  It is provided "as is" without express or implied warranty.
4200db7afdSDavid E. O'Brien *
4300db7afdSDavid E. O'Brien *
4400db7afdSDavid E. O'Brien * Copyright (c) 1996
4500db7afdSDavid E. O'Brien * Silicon Graphics Computer Systems, Inc.
4600db7afdSDavid E. O'Brien *
4700db7afdSDavid E. O'Brien * Permission to use, copy, modify, distribute and sell this software
4800db7afdSDavid E. O'Brien * and its documentation for any purpose is hereby granted without fee,
4900db7afdSDavid E. O'Brien * provided that the above copyright notice appear in all copies and
5000db7afdSDavid E. O'Brien * that both that copyright notice and this permission notice appear
5100db7afdSDavid E. O'Brien * in supporting documentation.  Silicon Graphics makes no
5200db7afdSDavid E. O'Brien * representations about the suitability of this software for any
5300db7afdSDavid E. O'Brien * purpose.  It is provided "as is" without express or implied warranty.
5400db7afdSDavid E. O'Brien */
5500db7afdSDavid E. O'Brien
5600db7afdSDavid E. O'Brien/** @file ext/rb_tree
5700db7afdSDavid E. O'Brien *  This file is a GNU extension to the Standard C++ Library (possibly
58*f8a1b7d9SAlexander Kabaev *  containing extensions from the HP/SGI STL subset).
5900db7afdSDavid E. O'Brien */
6000db7afdSDavid E. O'Brien
61ffeaf689SAlexander Kabaev#ifndef _RB_TREE
62ffeaf689SAlexander Kabaev#define _RB_TREE 1
6300db7afdSDavid E. O'Brien
6400db7afdSDavid E. O'Brien#pragma GCC system_header
65ffeaf689SAlexander Kabaev
6600db7afdSDavid E. O'Brien#include <bits/stl_tree.h>
6700db7afdSDavid E. O'Brien
68*f8a1b7d9SAlexander Kabaev_GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
69*f8a1b7d9SAlexander Kabaev
7000db7afdSDavid E. O'Brien  using std::_Rb_tree;
7100db7afdSDavid E. O'Brien  using std::allocator;
7200db7afdSDavid E. O'Brien
7300db7afdSDavid E. O'Brien  // Class rb_tree is not part of the C++ standard.  It is provided for
7400db7afdSDavid E. O'Brien  // compatibility with the HP STL.
7500db7afdSDavid E. O'Brien
76ca6500fcSAlexander Kabaev  /**
77ca6500fcSAlexander Kabaev   *  This is an SGI extension.
78ca6500fcSAlexander Kabaev   *  @ingroup SGIextensions
79ca6500fcSAlexander Kabaev   *  @doctodo
80ca6500fcSAlexander Kabaev   */
8100db7afdSDavid E. O'Brien  template <class _Key, class _Value, class _KeyOfValue, class _Compare,
8200db7afdSDavid E. O'Brien	    class _Alloc = allocator<_Value> >
83*f8a1b7d9SAlexander Kabaev    struct rb_tree
84*f8a1b7d9SAlexander Kabaev    : public _Rb_tree<_Key, _Value, _KeyOfValue, _Compare, _Alloc>
8500db7afdSDavid E. O'Brien    {
8600db7afdSDavid E. O'Brien      typedef _Rb_tree<_Key, _Value, _KeyOfValue, _Compare, _Alloc> _Base;
8700db7afdSDavid E. O'Brien      typedef typename _Base::allocator_type allocator_type;
8800db7afdSDavid E. O'Brien
8900db7afdSDavid E. O'Brien      rb_tree(const _Compare& __comp = _Compare(),
9000db7afdSDavid E. O'Brien	      const allocator_type& __a = allocator_type())
9100db7afdSDavid E. O'Brien      : _Base(__comp, __a) { }
9200db7afdSDavid E. O'Brien
9300db7afdSDavid E. O'Brien      ~rb_tree() { }
9400db7afdSDavid E. O'Brien    };
95*f8a1b7d9SAlexander Kabaev
96*f8a1b7d9SAlexander Kabaev_GLIBCXX_END_NAMESPACE
9700db7afdSDavid E. O'Brien
98ffeaf689SAlexander Kabaev#endif
99