-
Notifications
You must be signed in to change notification settings - Fork 44
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
Planned changes in 3.0 #52
Comments
Your C++17 planned changes looks great! A thought regarding the use of Regarding the namespaces. Schemagen idea, I think it would be interesting to be able to fully customize the generated code namespaces, so the generated code can integrate well with an existing code base which want to add GraphQL support. |
Making the parser/AST available separately is something I've been considering. I could spin it off into a separate project, or even just separate it into a separate library which is independently consumable. Maybe more ambitious would be to send a PR to the PEGTL project's contrib directory with the There's definitely room for improvement in the I originally picked |
For the parser, a separately consumable library in the project sounds reasonable to me, because for now there are not too many dependencies. Ah, thanks for the |
Actually, I just realized the Of course, if you're going to spin additional threads to execute the request concurrently anyway you could wrap that in your own |
Just FYI: We just released version 2.8.0 of the PEGTL, I backported almost all of the features from the master to C++11. I might have broken the link in your You may, however, rename the enumerators, etc. to make it also compatible with the master branch, as version 2.8.0 now supports both spellings for an easier transition. If you have any questions or need help just let us know. |
This is what I did. |
That's the last of the planned changes for 3.0. I'll go ahead and release it after a few days assuming no new issues crop up. |
I'm starting a list of improvements I'd like to make for 3.0. Many of these will break backwards compatibility, so I hope to do as many of them as possible in a single major version release.
Adopting C++17
std::variant
forresponse::Value
std::unique_ptr
for nullable fields withstd::optional
Schemagen improvements
Mutation
accessors to something likeapplyFieldName
. Calling everythinggetFieldName
feels strange when performing a mutation.Miscellaneous/TBD
std::launch
policy for theRequest::resolve
top-level call.std::unordered_map
with either a pre-sortedstd::vector
or generatedif
/else if
blocks?std::string
withstd::string_view
where appropriate.ast<std::string>
withast<std::string_view>
orast<std::vector<char>>
to deal with small-string-optimization issues rather than reserving extra space when the string is too short.facebook::graphql
namespace with justgraphql
for the sake of brevity.Documentation
Postponed to 3.1
The text was updated successfully, but these errors were encountered: