[PATCH] D76088: [Sema][SVE] Don't allow sizeless objects to be thrown
Richard Sandiford via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Mar 12 13:01:31 PDT 2020
rsandifo-arm added a comment.
In D76088#1920070 <https://reviews.llvm.org/D76088#1920070>, @efriedma wrote:
> Why is throwing an `svint8_t *` an error? I don't see any obvious reason to forbid that.
Yeah, I agree there's no obvious reason why it wouldn't work. The same reasoning applies here as for D76086 <https://reviews.llvm.org/D76086>:
> (In practice, throwing pointers to sizeless types could probably
> be handled without problems. It would be an odd thing to do though,
> and so it didn't seem worth treating as a special case.)
I.e. once sizeless types are treated as incomplete types (which happens towards the end of the series), we'd have to create a new rule to allow sizeless types only for the pointer case. But since no-one will hopefully want to throw such a thing, it seemed better to keep it simple and leave the rule unchanged.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D76088/new/
https://reviews.llvm.org/D76088
More information about the cfe-commits
mailing list