Bug 577503

Summary: The Empty arrays generated for CFBs are not accepted by Visual Studio C++ compiler
Product: [IoT] 4DIAC Reporter: Alois Zoitl <alois.zoitl>
Component: 4DIAC-IDEAssignee: Project Inbox <4diac-inbox>
Status: CLOSED FIXED QA Contact:
Severity: normal    
Priority: P3    
Version: 2.0.0   
Target Milestone: 2.0.1   
Hardware: PC   
OS: Linux   
See Also: https://git.eclipse.org/r/c/4diac/org.eclipse.4diac.ide/+/188225
https://git.eclipse.org/c/4diac/org.eclipse.4diac.ide.git/commit/?id=e0271a89800e800638c8b6e7b9b12db4dd24e0be
Whiteboard:

Description Alois Zoitl CLA 2021-11-28 10:05:50 EST
If there are certain elements not available in a CFB (e.g., parameters of internal FBs) our exporter generates arrays with empty initialization:

 const SCFB_FBParameter FORTE_AIT::scm_astParamters[] = {
 };

While Gcc is happy with this code the Visual Studio compiler reports Error C2466. As in this case the static value initialization is not needed at all it should be fine that we just do not export these lines to the CPP.

For more details see: https://www.eclipse.org/forums/index.php/t/1109531/
Comment 1 Eclipse Genie CLA 2021-11-28 10:08:36 EST
New Gerrit change created: https://git.eclipse.org/r/c/4diac/org.eclipse.4diac.ide/+/188225