Error: C2065: 'outValue': undeclared identifier

Hello, I’m trying to follow the “hello world” tutorial but when I try to compile using hxcpp it throws an error, Here is the complete error:

Error: BufferFlags_Impl_.cpp
./src/hxd/impl/Allocator/BufferFlags_Impl.cpp(54): error C2061: syntax error: identifier ‘Dynamic’
./src/hxd/impl/Allocator/BufferFlags_Impl.cpp(55): error C2511: ‘bool hxd::impl::_Allocator::BufferFlags_Impl__obj::__GetStatic(const String &)’: overloaded member function not found in ‘hxd::impl::_Allocator::BufferFlags_Impl__obj’
d:\HelloHeaps\build\include\hxd/impl/Allocator/BufferFlags_Impl.h(15): note: see declaration of ‘hxd::impl::_Allocator::BufferFlags_Impl__obj’
./src/hxd/impl/Allocator/BufferFlags_Impl.cpp(58): error C2065: ‘outValue’: undeclared identifier
Error: Build failed

My Haxe version is: 4.2.4
My Heaps version is the latest git version (I also tried with the latest stable version).

Finally I fixed this, I was trying to compile the tutorial using hxcpp but it worked when I used HashLink and C.

if this is true, this is pretty terrible. A broken hello world tutorial?? :sob:

haplesssly presses buttons

Error: In file included from ./src/__boot__.cpp:352:
include/hxd/impl/_Allocator/BufferFlags_Impl_.h:55:14: error: declaration of ‘int hxd::impl::_Allocator::BufferFlags_Impl__obj::Dynamic’ changes meaning of ‘Dynamic’ [-fpermissive]
   55 |   static int Dynamic;
      |              ^~~~~~~
In file included from /root/haxelib/hxcpp/4,2,1/include/hxcpp.h:353:
/root/haxelib/hxcpp/4,2,1/include/Dynamic.h:14:37: note: ‘Dynamic’ declared here as ‘class Dynamic’
   14 | class HXCPP_EXTERN_CLASS_ATTRIBUTES Dynamic : public hx::ObjectPtr<hx::Object>

hmmmmm, i think i’ve seen this before… :thinking:

i double-checked, and the docs have two tutorials: one for javascript and one for hashlink, and the hashlink tutorial contains both build options: interpreted VM and compiled C. I think hashlink sorta replaces the C++ target (via hxcpp)… but i’m no pro. :woman_shrugging:

interestingly, the generated C++ code for hello world without heaps is like 3 pages long. :joy:

anyway @ElCosmoXD, for help i’d suggest you just ask on the discord server channel. Someone knowledgeable is usually there. Forums are maybe left for topical discussions. Maybe. Or maybe we should just get rid of it completely …? :japanese_goblin:

1 Like

I actually fixed by just using HashLink because as far as I know Heaps just supports HashLink and JS but HashLink is really easy to use especially if you want to compile to C.

1 Like

okay, cool, glad you got that sorted out! :slight_smile:

1 Like