Skip to content
This repository has been archived by the owner on Mar 30, 2021. It is now read-only.

Enforce that node ctors in "to" ctx get params from the "to" ctx #649

Open
martong opened this issue Apr 16, 2019 · 0 comments
Open

Enforce that node ctors in "to" ctx get params from the "to" ctx #649

martong opened this issue Apr 16, 2019 · 0 comments

Comments

@martong
Copy link

martong commented Apr 16, 2019

I was wondering how could we avoid these errors when a node from the
"from" context is passed to a constructor of a node in the
"to"context.
This came up with the Concepts patches:
E.g. https://reviews.llvm.org/D43357#inline-538221
Since GetImportedOrCreateDecl is the one which forwards the nodes as
parameters, maybe with some template metaprogramming we could enforce
that all the forwarded nodes are in the "to" context ... but it is
still not a full coverage because there are nodes with additional
setSubexpression() functions which may be called after create:
https://reviews.llvm.org/D44352#inline-538212

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

No branches or pull requests

1 participant