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

Tuple Concatenation #56

Open
zaphar opened this issue Aug 31, 2021 · 0 comments
Open

Tuple Concatenation #56

zaphar opened this issue Aug 31, 2021 · 0 comments

Comments

@zaphar
Copy link
Owner

zaphar commented Aug 31, 2021

Some things would be more convenient to express if you could build up a tuple via expression.

For Example:

let base = { foo = "bar" };

let withField = select (expression) => {
  true = base{ count = 1 },
  false = base,
};

versus:

let withField = { foo = "bar" } + select (expression) => {
  true = { count = 1 },
  false = {},
};

The second variation is more concise. This however is not an orthogonal feature so it's worth considering if it is worth the weight. The implementation is essentially equal to the Copy operation on a tuple just an alternate syntax to express it.

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