[aspectc-user] UINT_MAX and an Assertion Failure

Gary Duzan gduzan at bbn.com
Wed Aug 6 23:46:17 CEST 2003

   As a bit of a torture test, I'm trying to add the Trace example aspect
to the Simple/echo example of the TAO ORB. I think I've set everything up
properly, but I still get the following output:

ac++ -v 9 -e cpp -D_POSIX_THREADS -D_POSIX_THREAD_SAFE_FUNCTIONS -D_REENTRANT -DACE_HAS_AIO_CALLS -DACE_HAS_RAPI -DACE_HAS_EXCEPTIONS -I/home/gduzan/work/ACE_wrappers -I/home/gduzan/work/ACE_wrappers/TAO -I/usr/include/rsvp -I/home/gduzan/work/ACE_wrappers/TAO/orbsvcs -I../echo -I. -d . -p ../echo -p aspects
* Running ac++ 0.7
* Simple Dependency Check
  - new or modified: ../echo/Echo_Client_i.h
  - new or modified: ../echo/Echo_i.h
  - new or modified: aspects/TestTrace.ah
  - new or modified: aspects/Trace.ah
* Handling Translation Unit `Echo_Client_i.cpp'.
  - Path "../echo/Echo_Client_i.cpp"
/home/gduzan/work/ACE_wrappers/ace/Basic_Types.h:126: error,: unsupported int size, must be updated for this platform!
  - Parsing ...
  - Weaving Introductions ...
  - intros for TestTrace4
  - Final checks before weaving introductions
  - Class Join Points
  - Weaving Advice Declarations ...
  - Weaving Singleton Aspects ...
  - Commiting
  - Parsing again ...
/home/gduzan/work/ACE_wrappers/ace/Basic_Types.h:126: error,: unsupported int size, must be updated for this platform!
  - Changing member protections ...
  - Weaving Join Points ...
    Collecting Advice
      TestTrace4: __a0_before
        Evaluate Pointcut
        Setting up thisJoinPoint
ac++: ThisJoinPoint.cc:22: void ThisJoinPoint::setup (CFunctionInfo *): Assertion `func->Tree ()->NodeName () == CT_FctDef::NodeId ()' failed.
make: *** [Echo_i.cpp] Aborted (core dumped)

   The Basic_Types code looks like this:

// The number of bytes in an int.
# if !defined (ACE_SIZEOF_INT)
#   if (UINT_MAX) == 65535U
#     define ACE_SIZEOF_INT 2
#   elif (UINT_MAX) == 4294967295U
#     define ACE_SIZEOF_INT 4
#   elif (UINT_MAX) == 18446744073709551615U
#     define ACE_SIZEOF_INT 8
#   else
#     error: unsupported int size, must be updated for this platform!
#   endif /* UINT_MAX */
# endif /* !defined (ACE_SIZEOF_INT) */

   I tried setting UINT_MAX in the puma.config and on the command line
with -D, but neither one changes the result.

   As for the assertion failure, I ran ac++ under gdb and got the
following information:

(gdb) frame 4
#4  0x08072479 in ThisJoinPoint::setup (this=0x8a2dce8, func=0x84ce4e0)
    at /home/gduzan/local/build/ac-sources-0.7/native/Puma/include/Puma/CObjectInfo.h:269
269      { return _Tree; }
(gdb) print func->_Tree->NodeName()
$1 = 0x81e4f03 "InitDeclarator"
(gdb) print CT_FctDef::NodeId()
$2 = 0x81e4e88 "FctDef"

   If I leave out the "-p aspects" option (I've put *.ah in an aspects
subdirectory) I still get the Basic_Types message, but it does manage
to make it through all the translation units (weaving in nothing).

   Any suggestions on where to go from here? Thanks.

   					Gary Duzan
					BBN Technologies
					A Verizon Company

More information about the aspectc-user mailing list