#1138 char enumitems not converting properly to proper enums

closed-fixed
csharp (36)
5
2011-03-26
2011-02-28
No

We are using Swig version 2.0.1 , platform Redhat AS5

For example for the following enum:

enum enCharType {
O1 = 1,
O2,
O3 = ‘A’,
O4
}

Converts to

public enum enCharType {
O1 = 1,
O2,
O3 = A,
O4
}

But the c# enum does not compile as O3=A is not valid..

Discussion

  • Koushik Nimmagadda

    • summary: char enumitems inot converting properly to proper enums --> char enumitems not converting properly to proper enums
     
  • William Fulton

    William Fulton - 2011-03-26
    • status: open --> closed-fixed
     
  • William Fulton

    William Fulton - 2011-03-26

    Fixed in trunk for swig-2.0.3. Use the %csconstvalue feature as a workaround in the meantime.

     

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.





No, thanks