Herb C Reference
Loading...
Searching...
No Matches
analyze_helpers.h
Go to the documentation of this file.
1#ifndef HERB_ANALYZE_HELPERS_H
2#define HERB_ANALYZE_HELPERS_H
3
4#include <prism.h>
5#include <stdbool.h>
6
7#include "analyzed_ruby.h"
8#include "ast_node.h"
9
10bool has_if_node(analyzed_ruby_T* analyzed);
11bool has_elsif_node(analyzed_ruby_T* analyzed);
12bool has_else_node(analyzed_ruby_T* analyzed);
13bool has_end(analyzed_ruby_T* analyzed);
14bool has_block_node(analyzed_ruby_T* analyzed);
16bool has_case_node(analyzed_ruby_T* analyzed);
18bool has_when_node(analyzed_ruby_T* analyzed);
19bool has_in_node(analyzed_ruby_T* analyzed);
20bool has_for_node(analyzed_ruby_T* analyzed);
21bool has_while_node(analyzed_ruby_T* analyzed);
22bool has_until_node(analyzed_ruby_T* analyzed);
23bool has_begin_node(analyzed_ruby_T* analyzed);
24bool has_rescue_node(analyzed_ruby_T* analyzed);
25bool has_ensure_node(analyzed_ruby_T* analyzed);
26bool has_unless_node(analyzed_ruby_T* analyzed);
27bool has_yield_node(analyzed_ruby_T* analyzed);
28bool has_then_keyword(analyzed_ruby_T* analyzed);
29
30bool has_error_message(analyzed_ruby_T* anlayzed, const char* message);
31
32bool is_do_block(pm_location_t opening_location);
33bool is_brace_block(pm_location_t opening_location);
34bool is_closing_brace(pm_location_t location);
35bool has_valid_block_closing(pm_location_t opening_loc, pm_location_t closing_loc);
36
37bool search_begin_nodes(const pm_node_t* node, void* data);
38bool search_block_nodes(const pm_node_t* node, void* data);
39bool search_case_match_nodes(const pm_node_t* node, void* data);
40bool search_case_nodes(const pm_node_t* node, void* data);
41bool search_for_nodes(const pm_node_t* node, void* data);
42bool search_if_nodes(const pm_node_t* node, void* data);
43bool search_in_nodes(const pm_node_t* node, void* data);
44bool search_then_keywords(const pm_node_t* node, void* data);
45bool search_unclosed_control_flows(const pm_node_t* node, void* data);
46bool search_unless_nodes(const pm_node_t* node, void* data);
47bool search_until_nodes(const pm_node_t* node, void* data);
48bool search_when_nodes(const pm_node_t* node, void* data);
49bool search_while_nodes(const pm_node_t* node, void* data);
50bool search_yield_nodes(const pm_node_t* node, void* data);
51
60
62
63#endif
bool is_do_block(pm_location_t opening_location)
Definition analyze_helpers.c:110
bool search_block_nodes(const pm_node_t *node, void *data)
Definition analyze_helpers.c:152
bool has_block_closing(analyzed_ruby_T *analyzed)
Definition analyze_helpers.c:28
bool has_until_node(analyzed_ruby_T *analyzed)
Definition analyze_helpers.c:56
bool search_unexpected_when_nodes(analyzed_ruby_T *analyzed)
Definition analyze_helpers.c:308
bool has_error_message(analyzed_ruby_T *anlayzed, const char *message)
Definition analyze_helpers.c:84
bool has_block_node(analyzed_ruby_T *analyzed)
Definition analyze_helpers.c:24
bool has_rescue_node(analyzed_ruby_T *analyzed)
Definition analyze_helpers.c:64
bool has_case_node(analyzed_ruby_T *analyzed)
Definition analyze_helpers.c:32
bool has_for_node(analyzed_ruby_T *analyzed)
Definition analyze_helpers.c:48
bool search_then_keywords(const pm_node_t *node, void *data)
Definition analyze_helpers.c:354
bool is_brace_block(pm_location_t opening_location)
Definition analyze_helpers.c:116
bool search_begin_nodes(const pm_node_t *node, void *data)
Definition analyze_helpers.c:219
bool search_while_nodes(const pm_node_t *node, void *data)
Definition analyze_helpers.c:189
bool search_yield_nodes(const pm_node_t *node, void *data)
Definition analyze_helpers.c:344
bool search_unexpected_ensure_nodes(analyzed_ruby_T *analyzed)
Definition analyze_helpers.c:335
bool search_for_nodes(const pm_node_t *node, void *data)
Definition analyze_helpers.c:199
bool has_elsif_node(analyzed_ruby_T *analyzed)
Definition analyze_helpers.c:12
bool search_unclosed_control_flows(const pm_node_t *node, void *data)
Definition analyze_helpers.c:396
bool search_case_match_nodes(const pm_node_t *node, void *data)
Definition analyze_helpers.c:179
bool search_until_nodes(const pm_node_t *node, void *data)
Definition analyze_helpers.c:209
bool has_if_node(analyzed_ruby_T *analyzed)
Definition analyze_helpers.c:8
bool has_when_node(analyzed_ruby_T *analyzed)
Definition analyze_helpers.c:40
bool search_unexpected_in_nodes(analyzed_ruby_T *analyzed)
Definition analyze_helpers.c:317
bool has_ensure_node(analyzed_ruby_T *analyzed)
Definition analyze_helpers.c:68
bool has_in_node(analyzed_ruby_T *analyzed)
Definition analyze_helpers.c:44
bool is_closing_brace(pm_location_t location)
Definition analyze_helpers.c:134
bool search_unexpected_end_nodes(analyzed_ruby_T *analyzed)
Definition analyze_helpers.c:285
bool search_unexpected_elsif_nodes(analyzed_ruby_T *analyzed)
Definition analyze_helpers.c:267
bool has_yield_node(analyzed_ruby_T *analyzed)
Definition analyze_helpers.c:76
bool search_unless_nodes(const pm_node_t *node, void *data)
Definition analyze_helpers.c:229
bool search_if_nodes(const pm_node_t *node, void *data)
Definition analyze_helpers.c:93
bool has_while_node(analyzed_ruby_T *analyzed)
Definition analyze_helpers.c:52
bool has_case_match_node(analyzed_ruby_T *analyzed)
Definition analyze_helpers.c:36
bool has_else_node(analyzed_ruby_T *analyzed)
Definition analyze_helpers.c:16
void check_erb_node_for_missing_end(const AST_NODE_T *node)
Definition analyze_missing_end.c:8
bool search_case_nodes(const pm_node_t *node, void *data)
Definition analyze_helpers.c:169
bool search_unexpected_else_nodes(analyzed_ruby_T *analyzed)
Definition analyze_helpers.c:276
bool search_unexpected_rescue_nodes(analyzed_ruby_T *analyzed)
Definition analyze_helpers.c:326
bool has_then_keyword(analyzed_ruby_T *analyzed)
Definition analyze_helpers.c:80
bool search_in_nodes(const pm_node_t *node, void *data)
Definition analyze_helpers.c:256
bool has_end(analyzed_ruby_T *analyzed)
Definition analyze_helpers.c:20
bool search_unexpected_block_closing_nodes(analyzed_ruby_T *analyzed)
Definition analyze_helpers.c:299
bool search_when_nodes(const pm_node_t *node, void *data)
Definition analyze_helpers.c:246
bool has_unless_node(analyzed_ruby_T *analyzed)
Definition analyze_helpers.c:72
bool has_valid_block_closing(pm_location_t opening_loc, pm_location_t closing_loc)
Definition analyze_helpers.c:142
bool has_begin_node(analyzed_ruby_T *analyzed)
Definition analyze_helpers.c:60
Definition analyzed_ruby.h:9
Definition ast_nodes.h:56