Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clean up old style error messages #3680

Open
karlnapf opened this issue Mar 6, 2017 · 2 comments
Open

Clean up old style error messages #3680

karlnapf opened this issue Mar 6, 2017 · 2 comments

Comments

@karlnapf
Copy link
Member

karlnapf commented Mar 6, 2017

We have many instances of something that looks like

SG_ERROR("%s::create_merged_copy(): Could not cast object of %s to same type as %s\n",get_name(), other->get_name(), get_name());

This task is to remove the %s::method_name and corresponding get_name(), as we can now use an internal loglevel to autogenerate this context, i.e. change it to

SG_ERROR("Could not cast object of %s to same type as %s\n",other->get_name(), get_name());

Grep for %s:: to find them. Super easy entrance task

Also, this particular error message is an example of a bad error message. They can also be cleaned up to something like

REQUIRE(other, "No feature object given.\n");
SG_ERROR("Given feature object (index %d, type %s), must have the same type as this instance (%s) %s\n", i, other->get_name(), get_name());
@aby0
Copy link
Contributor

aby0 commented Mar 6, 2017

Can I work on this issue?

@karlnapf
Copy link
Member Author

karlnapf commented Mar 6, 2017

Sure no need to ask

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants