Ruby
4.1.0dev (2026-04-07 revision 8dd73008e6945142a9c0bacc6e1bb84807d1f623)
prism
magic_comments.h
Go to the documentation of this file.
1
6
#ifndef PRISM_MAGIC_COMMENTS_H
7
#define PRISM_MAGIC_COMMENTS_H
8
9
#include "
prism/compiler/exported.h
"
10
#include "
prism/compiler/nonnull.h
"
11
12
#include "prism/ast.h"
13
14
#include <stddef.h>
15
17
typedef
struct
pm_magic_comment_t
pm_magic_comment_t
;
18
25
PRISM_EXPORTED_FUNCTION
pm_location_t
pm_magic_comment_key
(
const
pm_magic_comment_t
*
magic_comment
)
PRISM_NONNULL
(1);
26
33
PRISM_EXPORTED_FUNCTION
pm_location_t
pm_magic_comment_value
(
const
pm_magic_comment_t
*
magic_comment
)
PRISM_NONNULL
(1);
34
35
#endif
exported.h
PRISM_EXPORTED_FUNCTION
#define PRISM_EXPORTED_FUNCTION
By default, we compile with -fvisibility=hidden.
Definition
exported.h:20
pm_magic_comment_value
PRISM_EXPORTED_FUNCTION pm_location_t pm_magic_comment_value(const pm_magic_comment_t *magic_comment) PRISM_NONNULL(1)
Returns the location of the value associated with the given magic comment.
Definition
parser.c:204
pm_magic_comment_key
PRISM_EXPORTED_FUNCTION pm_location_t pm_magic_comment_key(const pm_magic_comment_t *magic_comment) PRISM_NONNULL(1)
Returns the location of the key associated with the given magic comment.
Definition
parser.c:196
nonnull.h
PRISM_NONNULL
#define PRISM_NONNULL(...)
Mark the parameters of a function as non-null.
Definition
nonnull.h:13
magic_comment
Definition
parse.c:21299
pm_location_t
This struct represents a slice in the source code, defined by an offset and a length.
Definition
ast.h:554
pm_magic_comment_t
Definition
magic_comments.h:12
Generated by
1.9.8