Has anyone used enum.h from Besser's ENUM++?

R

Randy

Hi,

I downloaded and tried the ENUM++ code from CUJ

http://www.cuj.com/documents/s=8470/cujboost0306besser/

but can't even get it to compile (see following). I
have also downloaded and installed the boost library.
This is using gcc under FC3.

Any ideas on what's wrong?

--Randy

PS: Besser's email, (e-mail address removed), is
no longer valid.



#include "enum.h"
int main(int argc, char **argv)
{
return 0;
}



cd /home/yates/modetest/host/app/modetest/
make -f enumpp.mak TARGET=native PLATFORM=linux
DSPROOT_DIR=/home/yates/modetest/ ATSIGN=
enumpp.mak:101: no file name for `include'
Building Component (enumpp) for Application enumpp
In file included from
/home/yates/modetest/host/app/modetest/enum.h:202,
from
/home/yates/modetest/host/app/modetest/enumpp.cpp:1:
/home/yates/modetest/host/app/modetest/StreamUDT.h: In function
`std::basic_ostream<_CharT, _Traits>&
KEA::stream_inserter(std::basic_ostream<_CharT, _Traits>&, const
UDT&)':
/home/yates/modetest/host/app/modetest/StreamUDT.h:96: error: expected
`;' before "prepost"
/home/yates/modetest/host/app/modetest/StreamUDT.h:97: error: `prepost'
undeclared (first use this function)
/home/yates/modetest/host/app/modetest/StreamUDT.h:97: error: (Each
undeclared identifier is reported only once for each function it
appears in.)
/home/yates/modetest/host/app/modetest/StreamUDT.h: In function
`std::basic_istream<_CharT, _Traits>&
KEA::stream_extractor(std::basic_istream<_CharT, _Traits>&, UDT&)':
/home/yates/modetest/host/app/modetest/StreamUDT.h:151: error: expected
`;' before "prepost"
/home/yates/modetest/host/app/modetest/StreamUDT.h:152: error:
`prepost' undeclared (first use this function)
In file included from
/home/yates/modetest/host/app/modetest/enumpp.cpp:1:
/home/yates/modetest/host/app/modetest/enum.h: At global scope:
/home/yates/modetest/host/app/modetest/enum.h:257: error: ISO C++
forbids declaration of `value_type' with no type
/home/yates/modetest/host/app/modetest/enum.h:257: error:
`::value_type' is not a valid declarator
/home/yates/modetest/host/app/modetest/enum.h:257: error: expected `;'
before "value_type"
/home/yates/modetest/host/app/modetest/enum.h:264: error: ISO C++
forbids declaration of `result_type' with no type
/home/yates/modetest/host/app/modetest/enum.h:264: error: expected `;'
before "operator"
/home/yates/modetest/host/app/modetest/enum.h:334: error: expected `;'
before '}' token
/home/yates/modetest/host/app/modetest/enum.h:338: error: ISO C++
forbids declaration of `result_type' with no type
/home/yates/modetest/host/app/modetest/enum.h:338: error: expected `;'
before "operator"
/home/yates/modetest/host/app/modetest/enum.h:344: error: expected `;'
before '}' token
/home/yates/modetest/host/app/modetest/enum.h:387: error: ISO C++
forbids declaration of `size_type' with no type
/home/yates/modetest/host/app/modetest/enum.h:387: error: `::size_type'
is not a valid declarator
/home/yates/modetest/host/app/modetest/enum.h:387: error: expected `;'
before "max_length"
/home/yates/modetest/host/app/modetest/enum.h:393: error: expected `;'
before "inline"
/home/yates/modetest/host/app/modetest/enum.h: In member function
`std::_Ios_Iostate KEA::_EnumSuper<_enumType, EnumSub,
N>::get_stream(std::basic_istream<_CharT2, _Traits2>&)':
/home/yates/modetest/host/app/modetest/enum.h:761: error: expected
primary-expression before "const"
/home/yates/modetest/host/app/modetest/enum.h:761: error: expected `;'
before "const"
/home/yates/modetest/host/app/modetest/enum.h:768: error:
`start_position' undeclared (first use this function)
/home/yates/modetest/host/app/modetest/enum.h: At global scope:
/home/yates/modetest/host/app/modetest/enum.h:789: error: expected
constructor, destructor, or type conversion before "_EnumSuper"
/home/yates/modetest/host/app/modetest/enum.h:789: error: expected `;'
before "_EnumSuper"
/home/yates/modetest/host/app/modetest/enum.h:805: error: expected
init-declarator before '&' token
/home/yates/modetest/host/app/modetest/enum.h:805: error: expected `;'
before '&' token
make: *** [/home/yates/modetest/host/app/modetest/nativelinux/enumpp.o]
Error 1

Compilation exited abnormally with code 2 at Fri Jan 6 11:41:16
 
V

Victor Bazarov

Randy said:
I downloaded and tried the ENUM++ code from CUJ
[...]

Randy, we heard you the first three times. If you've received no
response, it means either folks don't know the answer (like I, for
instance) or nobody is interested in sharing (although that is
rather unlikely). Repeating the question is not going to help.

Spend some time trying to figure it out, or wait a couple more days.
Another way is to post to comp.lang.c++.moderated. More CUJ readers
and writers hang out there. But you will need to wait for your
answer there as well, moderators do need time to sift through many
posts and it does introduce some latency.

V
 
R

Randy Yates

Victor Bazarov said:
Randy said:
I downloaded and tried the ENUM++ code from CUJ
[...]

Randy, we heard you the first three times. If you've received no
response, it means either folks don't know the answer (like I, for
instance) or nobody is interested in sharing (although that is
rather unlikely). Repeating the question is not going to help.

Victor,

You've misinterpreted the situation - Google news was apparently hosed up
yesterday. I reposted because I never saw *my own* post(s).
Spend some time trying to figure it out, or wait a couple more days.
Another way is to post to comp.lang.c++.moderated. More CUJ readers
and writers hang out there. But you will need to wait for your
answer there as well, moderators do need time to sift through many
posts and it does introduce some latency.

Thanks for the pointers, anyway, Victor.

PS Everyone: This problem has been (apparently and thankfully) solved
by MLimber but I can't try it until I get back to work on Monday. Thanks
for all your responses and help. I'll post a follow-up as soon as I can
get things to work.

Also, note that Mr. Besser's email address ([email protected]) is no
longer valid. Does anyone have an updated address for him?
--
% Randy Yates % "Ticket to the moon, flight leaves here today
%% Fuquay-Varina, NC % from Satellite 2"
%%% 919-577-9882 % 'Ticket To The Moon'
%%%% <[email protected]> % *Time*, Electric Light Orchestra
http://home.earthlink.net/~yatescr
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,743
Messages
2,569,478
Members
44,898
Latest member
BlairH7607

Latest Threads

Top