Thread overview | ||||||
---|---|---|---|---|---|---|
|
November 18, 2013 Enum with base type string and switch | ||||
---|---|---|---|---|
| ||||
Hi, I am experiencing the same issue as here: http://forum.dlang.org/thread/bug-10113-3@http.d.puremagic.com/issues/ I have the DMD 2.061 for Linux 64 bit In this thread. their is a mention of one -g switch. I am sorry but can'T figure out how to implement the said -g switch. Please help. |
November 18, 2013 Re: Enum with base type string and switch | ||||
---|---|---|---|---|
| ||||
Posted in reply to seany | On 2013-11-18 13:48, seany wrote: > Hi, I am experiencing the same issue as here: > http://forum.dlang.org/thread/bug-10113-3@http.d.puremagic.com/issues/ > > I have the DMD 2.061 for Linux 64 bit > > In this thread. their is a mention of one -g switch. I am sorry but > can'T figure out how to implement the said -g switch. > > Please help. Just pass -g on the command line, example: dmd main.d -g -- /Jacob Carlborg |
November 18, 2013 Re: Enum with base type string and switch | ||||
---|---|---|---|---|
| ||||
Posted in reply to Jacob Carlborg | On Monday, 18 November 2013 at 13:29:38 UTC, Jacob Carlborg wrote:
>
> Just pass -g on the command line, example:
>
> dmd main.d -g
Uh, that does not work, (same error message) but a
switch(cast(string)(enum_var))
seem to work
|
November 19, 2013 Re: Enum with base type string and switch | ||||
---|---|---|---|---|
| ||||
Posted in reply to seany | This was a bug and has since been fixed, so the solution is simply to update your compiler. If there is some reason you can't (company required version, etc) then your cast() is sadly probably the only way. |
Copyright © 1999-2021 by the D Language Foundation