|
|
|
|
|
|
|
|
|
|
|
|
|
Re: The type of the expression must be union or anytype [message #1833687 is a reply to message #1833681] |
Wed, 21 October 2020 14:15 |
|
Hi Gajula,
try adding the paths at the head, not the tail:
export TTCN3_DIR=/home/lalith/Downloads/ttcn3-7.1.pl0-linux64-gcc7-ubuntu_18.04.3_lts_foss
export PATH=$TTCN3_DIR/bin:$PATH
export LD_LIBRARY_PATH=$TTCN3_DIR/lib:$LD_LIBRARY_PATH
so they are found before any other path;
do these settings in a shell first, and see if they work;
"which compiler" should point to
/home/lalith/Downloads/ttcn3-7.1.pl0-linux64-gcc7-ubuntu_18.04.3_lts_foss/bin/compiler
and the command "compiler" should be answered accordingly.
If it works in a shell, you can add it to .bashrc
BR
Elemer
|
|
|
Re: The type of the expression must be union or anytype [message #1833754 is a reply to message #1833687] |
Fri, 23 October 2020 10:15 |
Gajula Lalithaditya Messages: 12 Registered: October 2020 |
Junior Member |
|
|
Hi Elemer
I Exported the TTCN3_DIR,PATH ,and LD_LIBRARY_PATH in the shell the compiler version changed and the compiler -v says
TTCN-3 and ASN.1 Compiler for the TTCN-3 Test Executor Product number: CRL 113 200/7 R1A Version: 7.1.pl0 .
and also the compiler in "ttcn3-7.1.pl0-linux64-gcc7-ubuntu_18.04.3_lts_foss/bin/compiler " answers the same.
So, i added the paths to .bashrc file.
But still the error of "The type of the expression must be union or anytype" is not solved.
Thanks and Regards
Lalithaditya
[Updated on: Fri, 23 October 2020 10:15] Report message to a moderator
|
|
|
|
|
|
|
|
|
|
Re: The type of the expression must be union or anytype [message #1833880 is a reply to message #1833877] |
Mon, 26 October 2020 19:27 |
|
HI Gajula,
here's my console log for 7.1.1:
ll
total 372
drwxrwxrwx 1 userid userid 4096 Oct 26 19:42 ./
drwxr-xr-x 1 userid userid 4096 Oct 19 17:59 ../
-rw-rw-rw- 1 userid userid 5005 Oct 16 15:52 Makefile
-rw-rw-rw- 1 userid userid 479 Oct 16 15:52 NR.ttcn
-rw-rw-rw- 1 userid userid 371804 Jun 29 12:53 NR_RRC_ASN1_Definitions.asn
drwxrwxrwx 1 userid userid 4096 Oct 16 17:46 backup/
which compiler
/home/userid/titan.core/Install/bin/compiler
userid@HU-00001378:~/Union$ compiler -v
TTCN-3 and ASN.1 Compiler for the TTCN-3 Test Executor
Product number: CRL 113 200/7 R1B
Version: 7.1.pl1
Build date: Sep 25 2020 10:05:41
Compiled with: GCC 9.3.0
Using OpenSSL 1.1.1f 31 Mar 2020
Copyright (c) 2000-2020 Ericsson Telecom AB
make
/home/userid/titan.core/Install/bin/compiler -L \
NR.ttcn NR_RRC_ASN1_Definitions.asn - NR.ttcn NR_RRC_ASN1_Definitions.asn
Notify: Parsing TTCN-3 module `NR.ttcn'...
Notify: Parsing ASN.1 module `NR_RRC_ASN1_Definitions.asn'...
NR_RRC_ASN1_Definitions.asn:9: warning: Missing IMPORTS clause is interpreted as `IMPORTS ;' (import nothing) instead of importing all symbols from all modules.
Notify: Checking modules...
Notify: Generating code...
Notify: File `NR.hh' was generated.
Notify: File `NR.cc' was generated.
Notify: File `NR_RRC_ASN1_Definitions.hh' was generated.
Notify: File `NR_RRC_ASN1_Definitions.cc' was generated.
Notify: 4 files were updated.
touch compile
g++ -c -DLINUX -I/home/userid/titan.core/Install/include -Wall -o NR.o NR.cc
g++ -c -DLINUX -I/home/userid/titan.core/Install/include -Wall -o NR_RRC_ASN1_Definitions.o NR_RRC_ASN1_Definitions.cc
NR_RRC_ASN1_Definitions.cc: In copy constructor 'NR__RRC__ASN1__Definitions::MeasObjectNR_blackCellsToAddModList::MeasObjectNR_blackCellsToAddModList(const NR__RRC__ASN1__Definitions::MeasObjectNR_blackCellsToAddModList&)':
NR_RRC_ASN1_Definitions.cc:395121: note: '-Wmisleading-indentation' is disabled from this point onwards, since column-tracking was disabled due to the size of the code/headers
395121 | val_ptr = other_value.val_ptr;
|
if g++ -o NR NR.o NR_RRC_ASN1_Definitions.o \
-L/home/userid/titan.core/Install/lib -lttcn3-parallel \
-L/lib -lcrypto \
-L/home/userid/titan.core/Install/lib -lxml2; \
then : ; else /home/userid/titan.core/Install/bin/titanver NR.o NR_RRC_ASN1_Definitions.o ; exit 1; fi
ll
total 521776
drwxrwxrwx 1 userid userid 4096 Oct 26 19:50 ./
drwxr-xr-x 1 userid userid 4096 Oct 19 17:59 ../
-rw-rw-rw- 1 userid userid 5005 Oct 16 15:52 Makefile
-rwxrwxrwx 1 userid userid 93052600 Oct 26 19:50 NR*
-rw-rw-rw- 1 userid userid 2927 Oct 26 19:43 NR.cc
-rw-rw-rw- 1 userid userid 1135 Oct 26 19:43 NR.hh
-rw-rw-rw- 1 userid userid 8328 Oct 26 19:43 NR.o
-rw-rw-rw- 1 userid userid 479 Oct 16 15:52 NR.ttcn
-rw-rw-rw- 1 userid userid 371804 Jun 29 12:53 NR_RRC_ASN1_Definitions.asn
-rw-rw-rw- 1 userid userid 90739980 Oct 26 19:43 NR_RRC_ASN1_Definitions.cc
-rw-rw-rw- 1 userid userid 13247831 Oct 26 19:43 NR_RRC_ASN1_Definitions.hh
-rw-rw-rw- 1 userid userid 143673064 Oct 26 19:50 NR_RRC_ASN1_Definitions.o
drwxrwxrwx 1 userid userid 4096 Oct 16 17:46 backup/
-rw-rw-rw- 1 userid userid 0 Oct 26 19:43 compile
I have also tried 7.1.0 and 6.6.0 and those work as well.
So I suggest you remove every Titan install form your machine and start from scratch with 7.1.1.
I suspect you are somehow still engaging 6.3.1 which gives you the same error again and again.
BR
Elemer
|
|
|
|
Re: The type of the expression must be union or anytype [message #1834039 is a reply to message #1834027] |
Fri, 30 October 2020 16:44 |
|
Hi Gajula,
OK, it's the first time I hear about the Eclipse plug-ins being involved; so far you led me believe that you are working with the compiler on command line only.
So here's the situation: the Eclipse plug-ins can be used in a number of modes, but let's focus on one mode only,
namely them playing the role of an IDE as a front-end to the TTCN-3 compiler and executor (a.k.a. "compiler").
Now the compiler and the Eclipse part have independent syntactical/semantical analyses; so even of the Eclipse plug-in indicates
an error, that has no influence over the compiler. Which means you should simply disregard the error indication; it will have no effect
on the build performed by the compiler.
Of course , the compiler can be used in complete stand-alone mode, without the IDE (possibly paired with an editor that supports TTCN-3),
and many users prefer this mode.
(BTW, the error has been fixed in the latest version of the plug-ins that will be available soon; but this should not influence what you are doing).
However, there are other things that should be considered:
it appears that you are trying to compile and probably execute a test suite from 3gpp.
These test suites are only complete from TTCN-3 point of view, meaning that they are missing the parts which are non-standard and implementation specific;
As I have discussed this in several earlier posts, these parts are: codecs, test ports and external functions.
If you want to have an executable , you will have to add these yourself to your project.
Again, details have been discussed in afore-mentioned earlier posts.
Now, adding these will require an in-depth knowledge of several areas, including C/C++ programming.
So if you want to continue, please evaluate if you have sufficient resources to drive your project to conclusion.
Best regards
Elemer
|
|
|
Powered by
FUDForum. Page generated in 0.04896 seconds