delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/11/17/03:16:19

From: ao950 AT FreeNet DOT Carleton DOT CA (Paul Derbyshire)
Newsgroups: comp.os.msdos.djgpp
Subject: Re: Mysterious C++ STL compiler message
Date: 17 Nov 1997 05:32:40 GMT
Organization: The National Capital FreeNet
Lines: 17
Message-ID: <64okto$ce4@freenet-news.carleton.ca>
References: <42256551 DOT 00400BFF DOT 00 AT aks DOT com>
Reply-To: ao950 AT FreeNet DOT Carleton DOT CA (Paul Derbyshire)
NNTP-Posting-Host: freenet6.carleton.ca
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp

Actually, enums ARE ints "under the hood". And enums are as valid as
anything else as container contained-thing types. The problem is here:

>>    (operators theOp, stack<operators> & opStack, String & result)

Stack is a containor adaptor, not a straight container. Stack's template
parameter is supposed to be a container class (typically deque or list)
whose parameter is, in turn, the contained type.

stack< list<operators> > should work.

--
    .*.  Where feelings are concerned, answers are rarely simple [GeneDeWeese]
 -()  <  When I go to the theater, I always go straight to the "bag and mix"
    `*'  bulk candy section...because variety is the spice of life... [me]
Paul Derbyshire ao950 AT freenet DOT carleton DOT ca, http://chat.carleton.ca/~pderbysh

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019