bulbazord wrote: > Pushed again to address David's comments and remove most of the FIXMEs. > There's one FIXME I've kept in for now: > > ``` > // FIXME: SB class server references are stored as non-const references so > // that we can actually change them as needed. If a parameter is marked > // const, we will fail to compile because we cannot make an > // SBFooServerReference from a `const SBFoo &`. > // To work around this issue, we'll apply a `const_cast` if needed so we > // can continue to generate callbacks for now, but we really should > // rethink the way we store object IDs server-side to support > // const-qualified parameters. > ``` > > @bulbazord This is referring to how we emit storage for const SB parameters > in callback functions. Currently it looks like it only gets applied to one > function that gets generated. Any thoughts here?
Given it only applies to one function, it's probably okay to keep it around for now. The fact that we need a `const_cast` at all is concerning but I think we've done a reasonably alright job at explaining why it exists (though I am a partial author, so maybe my perspective is biased). https://github.com/llvm/llvm-project/pull/138032 _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits