Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,9 +54,12 @@ jobs:
ruby: 3.3
- gemfile: gemfiles/rails_master.gemfile
ruby: 3.3
graphql_reject_numbers_followed_by_names: 1
runs-on: ubuntu-latest
steps:
- run: echo BUNDLE_GEMFILE=${{ matrix.gemfile }} > $GITHUB_ENV
- run: echo GRAPHQL_REJECT_NUMBERS_FOLLOWED_BY_NAMES=1 > $GITHUB_ENV
if: ${{ !!matrix.graphql_reject_numbers_followed_by_names }}
- uses: actions/checkout@v4
- uses: ruby/setup-ruby@v1
with:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#include "graphql_c_parser_ext.h"

VALUE GraphQL_CParser_Lexer_tokenize_with_c_internal(VALUE self, VALUE query_string, VALUE fstring_identifiers) {
return tokenize(query_string, RTEST(fstring_identifiers));
VALUE GraphQL_CParser_Lexer_tokenize_with_c_internal(VALUE self, VALUE query_string, VALUE fstring_identifiers, VALUE reject_numbers_followed_by_names) {
return tokenize(query_string, RTEST(fstring_identifiers), RTEST(reject_numbers_followed_by_names));
}

VALUE GraphQL_CParser_Parser_c_parse(VALUE self) {
Expand All @@ -13,7 +13,7 @@ void Init_graphql_c_parser_ext() {
VALUE GraphQL = rb_define_module("GraphQL");
VALUE CParser = rb_define_module_under(GraphQL, "CParser");
VALUE Lexer = rb_define_module_under(CParser, "Lexer");
rb_define_singleton_method(Lexer, "tokenize_with_c_internal", GraphQL_CParser_Lexer_tokenize_with_c_internal, 2);
rb_define_singleton_method(Lexer, "tokenize_with_c_internal", GraphQL_CParser_Lexer_tokenize_with_c_internal, 3);
setup_static_token_variables();

VALUE Parser = rb_define_class_under(CParser, "Parser", rb_cObject);
Expand Down
Loading