[PATCH] D47991: Improve SBThread's stepping API using SBError parameter.

Adrian Prantl via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jun 21 08:57:25 PDT 2018


aprantl added a comment.

In https://reviews.llvm.org/D47991#1139249, @clayborg wrote:

> that is the right way to do it, but we can't overload on return type only. We will need the old version of the code to be in the API for compatibility. Overloading by return type will result is two symbols with the same name. If we change the API over to return an SBError, we will crash programs that linked against the old API as it now becomes returns something, possibly a struct return type, so it will crash older programs.


I get that. My question was whether it is better to add a new overload that adds an SBError& argument versus adding a new overload that returns and SBError *and* has a different name. In any case, Jim pointed out that we are using both variants in other places, so it doesn't really seem to matter.


Repository:
  rL LLVM

https://reviews.llvm.org/D47991





More information about the llvm-commits mailing list