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

Allow creation of defer nodes for custom types #1854

Open
3 tasks
evgenykochetkov opened this issue Sep 19, 2019 · 0 comments
Open
3 tasks

Allow creation of defer nodes for custom types #1854

evgenykochetkov opened this issue Sep 19, 2019 · 0 comments

Comments

@evgenykochetkov
Copy link
Contributor

evgenykochetkov commented Sep 19, 2019

Right now only xod/core/defer(*) count as defer nodes:

//
// defer-* nodes
//
const legacyDeferNodeRegExp = new RegExp(
`^xod/core/defer-(${dataTypes.join('|')})$`
);
// TODO: when custom types will be added this should be generalized
const deferNodeSpecializationRegExp = new RegExp(
`^xod/core/defer\\((${dataTypes.join('|')})\\)$`
);
// :: PatchPath -> Boolean
export const isDeferNodeType = R.anyPass([
R.equals('xod/core/defer'),
R.test(deferNodeSpecializationRegExp),
R.test(legacyDeferNodeRegExp),
]);

Those restrictions have to be relaxed.

  • Any node named defer(typename) should be considered a defer node if:

    • it has a single input of type input-typename
    • it has a single output of type output-typename
    • it's implemented in C++
  • Abstract xod/core/defer should correctly resolve to defer(typename)

  • isEarlyDeferPass function introduced in Improve error propagation through defer nodes #1873 should be added to documentation

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