MSLException hanldle and cause are empty

6 visualizaciones (últimos 30 días)
Milos
Milos el 27 de Mzo. de 2018
Comentada: Milos el 10 de Abr. de 2018
I am trying to port some 2012B Simulink code into 2016B and I get
---------------------------------------------------------------------- Unable to generate code using bus object 'struct_gXHXfJxyCgdYSgjadAsrfG' because it has an element named 'const' which conflicts with a programming language reserved identifier -----------------------------------------------------------------------
both cause and handle in MSLException are empty.
There is no 'const' in the model, there are Constant blocks.

Respuestas (1)

Sonam Gupta
Sonam Gupta el 30 de Mzo. de 2018
The error occurs if you use elements of a MATLAB structure as block parameters, and the structure has element names that are reserved words in C. To work around the error, change the element names so they do not conflict with reserved words. For example, use x._const instead of x.const.
I hope this helps.
  1 comentario
Milos
Milos el 10 de Abr. de 2018
I understand THAT, but which structure is it? 'struct_gXHXfJxyCgdYSgjadAsrfG' is not telling me much...

Iniciar sesión para comentar.

Categorías

Más información sobre General Applications en Help Center y File Exchange.

Etiquetas

Productos

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by