Skip to content

Commit 0bf824e

Browse files
committed
Add unchecked field to TypeParam node
Signed-off-by: Alexandre Terrasa <[email protected]>
1 parent c04a6b0 commit 0bf824e

File tree

3 files changed

+4
-2
lines changed

3 files changed

+4
-2
lines changed

config.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -191,6 +191,7 @@ nodes:
191191
- name: variance
192192
- name: upper_bound
193193
- name: default_type
194+
- name: unchecked
194195
- name: location
195196
- name: RBS::MethodType
196197
fields:

include/rbs/ruby_objs.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ VALUE rbs_ast_members_method_definition_overload(VALUE annotations, VALUE method
3939
VALUE rbs_ast_members_prepend(VALUE name, VALUE args, VALUE annotations, VALUE location, VALUE comment);
4040
VALUE rbs_ast_members_private(VALUE location);
4141
VALUE rbs_ast_members_public(VALUE location);
42-
VALUE rbs_ast_type_param(VALUE name, VALUE variance, VALUE upper_bound, VALUE default_type, VALUE location);
42+
VALUE rbs_ast_type_param(VALUE name, VALUE variance, VALUE upper_bound, VALUE default_type, VALUE unchecked, VALUE location);
4343
VALUE rbs_method_type(VALUE type_params, VALUE type, VALUE block, VALUE location);
4444
VALUE rbs_namespace(VALUE path, VALUE absolute);
4545
VALUE rbs_type_name(VALUE namespace, VALUE name);

src/ruby_objs.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -435,12 +435,13 @@ VALUE rbs_ast_members_public(VALUE location) {
435435
);
436436
}
437437

438-
VALUE rbs_ast_type_param(VALUE name, VALUE variance, VALUE upper_bound, VALUE default_type, VALUE location) {
438+
VALUE rbs_ast_type_param(VALUE name, VALUE variance, VALUE upper_bound, VALUE default_type, VALUE unchecked, VALUE location) {
439439
VALUE _init_kwargs = rb_hash_new();
440440
rb_hash_aset(_init_kwargs, ID2SYM(rb_intern("name")), name);
441441
rb_hash_aset(_init_kwargs, ID2SYM(rb_intern("variance")), variance);
442442
rb_hash_aset(_init_kwargs, ID2SYM(rb_intern("upper_bound")), upper_bound);
443443
rb_hash_aset(_init_kwargs, ID2SYM(rb_intern("default_type")), default_type);
444+
rb_hash_aset(_init_kwargs, ID2SYM(rb_intern("unchecked")), unchecked);
444445
rb_hash_aset(_init_kwargs, ID2SYM(rb_intern("location")), location);
445446

446447
return CLASS_NEW_INSTANCE(

0 commit comments

Comments
 (0)