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

Add a way to disable default layout definitions. #134

Open
timothee-haudebourg opened this issue Apr 28, 2023 · 0 comments
Open

Add a way to disable default layout definitions. #134

timothee-haudebourg opened this issue Apr 28, 2023 · 0 comments

Comments

@timothee-haudebourg
Copy link
Collaborator

When a type is defined in TreeLDR, it also defines a default layout for this type. This is very useful sometimes, but not all the time. We should add a way to disable this behavior. I see two ways of doing this:

  • Generate by default, disable explicitly:
// Foo is a type and a layout.
type Foo {
  ...
}

// Bar is just a type, not a layout.
type Bar {
  ...
} nolayout;
  • Disable by default, generate explicitly:
// Foo is just a type, not a layout.
type Foo {
  ...
}

// Bar is a type and a layout.
type layout Bar {
  ...
}
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