Ruby: parser_node.h Source File

Ruby 3.3.6p108 (2024-11-05 revision 75015d4c1f6965b5e85e96fb309f1f2129f933c0)

parser_node.h
1#ifndef RUBY_PARSER_NODE_H
2#define RUBY_PARSER_NODE_H 1
3/*
4 * This is a header file used by only "parse.y"
5 */
6#include "rubyparser.h"
7#include "internal/compilers.h"
8
9#if defined(__cplusplus)
10extern "C" {
11#if 0
12} /* satisfy cc-mode */
13#endif
14#endif
15
16static inline rb_code_location_t
17code_loc_gen(const rb_code_location_t *loc1, const rb_code_location_t *loc2)
18{
19 rb_code_location_t loc;
20 loc.beg_pos = loc1->beg_pos;
21 loc.end_pos = loc2->end_pos;
22 return loc;
23}
24
25#if defined(__cplusplus)
26#if 0
27{ /* satisfy cc-mode */
28#endif
29} /* extern "C" { */
30#endif
31
32#endif /* RUBY_PARSER_NODE_H */
rb_code_location_struct
Definition rubyparser.h:160