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

special handling for ^<att> #50

Open
garfieldnate opened this issue Mar 7, 2025 · 0 comments
Open

special handling for ^<att> #50

garfieldnate opened this issue Mar 7, 2025 · 0 comments

Comments

@garfieldnate
Copy link
Contributor

This production will never validate against any datamap:

sp {foo
   (state <s> ^name <name>)
-->
   (<s> ^<name> name)
}

The problem is the creation of the dynamically-named attribute ^<name> in the RHS. DM validation would have to be made more advanced to do any real checking here:

  • enumerate the possible values for
  • iterate over those values and check each against the DM

This could get very expensive for dynamic attributes that have deep sub-structures that possibly contain more dynamic attributes.

For now, I would like to just update the DM feedback for this case:

could not match constraint (<s>,<name>,name) in production

This is the same exact message that's used for any other validation error. This error should be more of a warning saying that V-S is not able to validate the attribute, rather than an error that the attribute is invalid.

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

No branches or pull requests

1 participant