Open thareh opened 1 year ago
With latest bcc the modules can no longer use framework
.
you need to use:
SuperStrict
Module Test.Generics
Import BRL.Blitz
Import BRL.Collections
Type TTempMap<K, V>
Field map:TTreeMap<K, V> = New TTreeMap<K, V>()
EndType
It blamed an incorrect module line at the first try but then in the second processed a bit more until it errored out:
Building untitled2
[ 14%] Processing:generics.bmx
[ 88%] Compiling:generics.bmx.release.linux.x64.c
[ 91%] Compiling:untitled2.bmx.console.release.linux.x64.c
In file included from /home/ronny/Arbeit/Tools/BlitzMaxNG/tmp/.bmx/untitled2.bmx.console.release.linux.x64.c:1:
/home/ronny/Arbeit/Tools/BlitzMaxNG/tmp/.bmx/untitled2.bmx.console.release.linux.x64.h:637:20: error: conflicting types for âbbbrl_blitz_IIterator_Current_mâ; have âBBString * (*)(struct bbbrl_blitz_IIterator_obj *)â
637 | typedef BBSTRING (*bbbrl_blitz_IIterator_Current_m)(struct bbbrl_blitz_IIterator_obj*);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/ronny/Arbeit/Tools/BlitzMaxNG/tmp/.bmx/untitled2.bmx.console.release.linux.x64.h:340:47: note: previous declaration of âbbbrl_blitz_IIterator_Current_mâ with type âbbbrl_blitz_IIterator_Current_mâ {aka âstruct _m_untitled2_TMapNodeSS_obj * (*)(struct bbbrl_blitz_IIterator_obj *)â}
340 | typedef struct _m_untitled2_TMapNodeSS_obj* (*bbbrl_blitz_IIterator_Current_m)(struct bbbrl_blitz_IIterator_obj*);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/ronny/Arbeit/Tools/BlitzMaxNG/tmp/.bmx/untitled2.bmx.console.release.linux.x64.h:638:10: error: conflicting types for â_bbbrl_blitz_IIterator_Currentâ; have âBBString *(struct bbbrl_blitz_IIterator_obj *)â
638 | BBSTRING _bbbrl_blitz_IIterator_Current(struct bbbrl_blitz_IIterator_obj*);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/ronny/Arbeit/Tools/BlitzMaxNG/tmp/.bmx/untitled2.bmx.console.release.linux.x64.h:341:37: note: previous declaration of â_bbbrl_blitz_IIterator_Currentâ with type âstruct _m_untitled2_TMapNodeSS_obj *(struct bbbrl_blitz_IIterator_obj *)â
341 | struct _m_untitled2_TMapNodeSS_obj* _bbbrl_blitz_IIterator_Current(struct bbbrl_blitz_IIterator_obj*);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
...
Good day,
Using the following code will cause a lot of compilation errors.
test.mod/generics.mod/generics.bmx
example.bmx
If you uncomment the if-block it works.
Thanks!