Skip to content

Conversation

@bbakerman
Copy link
Member

@bbakerman bbakerman commented Nov 11, 2020

This make the AST elements use immutable lists inside themselves (for performance reasons since they are created on every request but we have convenience methods for the single item add methods from before.

Related to #2099

@bbakerman bbakerman requested a review from andimarek November 11, 2020 12:10
@bbakerman bbakerman added this to the 16.0 milestone Nov 11, 2020
Copy link
Member

@andimarek andimarek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

see the one comment, but not really needed now. LGTM

private ImmutableList<Directive> directives = emptyList();
private ImmutableList<InputValueDefinition> inputValueDefinitions = emptyList();
private IgnoredChars ignoredChars = IgnoredChars.EMPTY;
private Map<String, String> additionalData = new LinkedHashMap<>();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we could change this to ImmutableMap or ImmutableMapWithNullValue too.

@bbakerman bbakerman merged commit 3dfeae3 into master Nov 15, 2020
@andimarek andimarek deleted the ast-builders-use-immutables branch May 4, 2021 21:06
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

Successfully merging this pull request may close these issues.

3 participants