# \[generated.h\] Forward declaring Struct instead of Class FBox2D

**URL:** <https://forums.unrealengine.com/t/generated-h-forward-declaring-struct-instead-of-class-fbox2d/337911>\
**Category:** C++\
**Tags:** unreal-engine, generated, CPP, question\
**Created:** [November 9, 2015, 10:29am UTC](https://forums.unrealengine.com/t/generated-h-forward-declaring-struct-instead-of-class-fbox2d/337911 "2015-11-09T10:29:38Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![HaltaeXS](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@HaltaeXS](https://forums.unrealengine.com/u/HaltaeXS)\
**Post date:** [November 9, 2015, 10:29am UTC](https://forums.unrealengine.com/t/generated-h-forward-declaring-struct-instead-of-class-fbox2d/337911/1 "2015-11-09T10:29:38Z")

</div>

Hello.  
I’m having an interesting trouble using FBox2D.

When I build my c++ project with FBox2D, the generated header forward declares “struct FBox2D” instead of class, and then the compiler outputs error C4099 (meaning the forward declaration is wrong).  
I have to change it myself in the generated.h to make it work, do you know what might be causing this?  
Thank you.

---

<div class="post-metadata">

**Author:** ![Steve\_Robb](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Steve\_Robb](https://forums.unrealengine.com/u/Steve_Robb)\
**Post date:** [November 10, 2015, 12:16pm UTC](https://forums.unrealengine.com/t/generated-h-forward-declaring-struct-instead-of-class-fbox2d/337911/2 "2015-11-10T12:16:19Z")

</div>

Hi,

This was a bug which was fixed and should be available in the 4.10 release. In the meantime you can fix it in your own code by simply changing the definition of FBox2D in Engine/Source/Runtime/Core/Public/Math/Box2D.h from class to struct.

Hope this helps,

Steve
