• Advertisement
Sign in to follow this  

Option to have build errors in a data structure instead of a string

This topic is 4324 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I was wondering if it would be possible to get an array/list of data structures instead of using the OutputStream for errors that occur while building a module. For instance, a struct/class containing the section name, error type, line number, column number, error message, etc. This would allow for application writers to easily reformat/eliminate part of the error messages. Not really much of an issue, but it might be nice to have. Thanks, Zoma

Share this post


Link to post
Share on other sites
Advertisement
I think that is a great idea.

What I have done is on the asIScriptOutstream write() method is just throw each error string into an array (vector) that I can then pull the error line and column out of. However, it would be great if there was some sort of struct:

struct:
line
column
type
message

Share this post


Link to post
Share on other sites
yes, this is indeed a not-optional feature that the application engine writer should have (i already throw it in http://www.gamedev.net/community/forums/topic.asp?topic_id=384829). i thought also to have in the struct a error "type" property (and error "identifier" of course), so you'll know if is a compiling error, an exception or a warnings, so you can output to the script writer what kind of troubles they could have, or even filter them in some cases (especially similar type conversion warnings that script can live with...).

Share this post


Link to post
Share on other sites
This is a good idea. Add that with the message ID that kunitoki suggested in the other thread, and it will be really generic.

I'll add this to the to-do list.

Thanks for the idea.

Regards,
Andreas

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement