Skip to content

Commit

Permalink
- use for mmcTypeShort in case of T_COMPLEX not error function becaus…
Browse files Browse the repository at this point in the history
…e get an error but found not the wrong code seems to be odd

git-svn-id: https://openmodelica.org/svn/OpenModelica/trunk@13672 f25d12d1-65f4-0310-ae8a-bbce733d8d8e
  • Loading branch information
Jens Frenkel committed Oct 28, 2012
1 parent 2a0652e commit 8286ede
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions Compiler/Template/CodegenC.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -7739,6 +7739,24 @@ template mmcTypeShort(DAE.Type type)
case T_ARRAY(__) then "array"
case T_METATYPE(__) case T_METABOXED(__) then "metatype"
case T_FUNCTION_REFERENCE_VAR(__) then "fnptr"


case T_NORETCALL(__) then error(sourceInfo(), 'mmcTypeShort:ERROR T_NORETCALL')
case T_UNKNOWN(__) then error(sourceInfo(), 'mmcTypeShort:ERROR T_UNKNOWN')
case T_COMPLEX(__) then 'mmcTypeShort:ERROR T_COMPLEX'
case T_SUBTYPE_BASIC(__) then error(sourceInfo(), 'mmcTypeShort:ERROR T_SUBTYPE_BASIC')
case T_FUNCTION(__) then error(sourceInfo(), 'mmcTypeShort:ERROR T_FUNCTION')
case T_FUNCTION_REFERENCE_FUNC(__) then error(sourceInfo(), 'mmcTypeShort:ERROR T_FUNCTION_REFERENCE_FUNC')
case T_TUPLE(__) then error(sourceInfo(), 'mmcTypeShort:ERROR T_TUPLE')
case T_CODE(__) then error(sourceInfo(), 'mmcTypeShort:ERROR T_CODE')
case T_ANYTYPE(__) then error(sourceInfo(), 'mmcTypeShort:ERROR T_ANYTYPE')
case T_METALIST(__) then error(sourceInfo(), 'mmcTypeShort:ERROR T_METALIST')
case T_METATUPLE(__) then error(sourceInfo(), 'mmcTypeShort:ERROR T_METATUPLE')
case T_METAOPTION(__) then error(sourceInfo(), 'mmcTypeShort:ERROR T_METAOPTION')
case T_METAUNIONTYPE(__) then error(sourceInfo(), 'mmcTypeShort:ERROR T_METAUNIONTYPE')
case T_METARECORD(__) then error(sourceInfo(), 'mmcTypeShort:ERROR T_METARECORD')
case T_METAARRAY(__) then error(sourceInfo(), 'mmcTypeShort:ERROR T_METAARRAY')
case T_METAPOLYMORPHIC(__) then error(sourceInfo(), 'mmcTypeShort:ERROR T_METAPOLYMORPHIC')
else error(sourceInfo(), 'mmcTypeShort:ERROR')
end mmcTypeShort;

Expand Down

0 comments on commit 8286ede

Please sign in to comment.