PIPS
|
#include "local.h"
Go to the source code of this file.
Macros | |
#define | FATAL(msg, value) {fprintf(stderr,msg,value);exit(1);} |
This file contains a set of functions defined to walk through the internal representation of a module and chek different things, as the number of arguments, the compatibility of the types of these arguments, ... More... | |
Functions | |
void | flint_cons_dimension (list pc) |
The only global variable : the name of the current module. More... | |
dimension | flint_dimension (dimension d) |
call | flint_call (call c) |
This function checks the syntax of a call and recursively. More... | |
range | flint_range (range r) |
This function verifies that incremented or decremented More... | |
reference | flint_reference (reference r) |
A reference is used when given a function the address of. More... | |
void | flint_syntax (syntax s) |
verification of syntaxes More... | |
void | flint_cons_expression (list pc) |
These two functions operate on the list of expressions More... | |
void | flint_cons_actual_argument (list pc) |
expression | flint_expression (expression e) |
loop | flint_loop (loop l) |
Recursive verification of a loop as (range)+(expression) More... | |
test | flint_test (test t) |
A test is taken as (expression)+(statement)+(statement) More... | |
instruction | flint_instruction (instruction i) |
Verification of an instruction with branching according More... | |
void | flint_unstructured (unstructured u) |
void | flint_cons_statement (list pc) |
statement | flint_statement (statement s) |
Variables | |
statement | flint_current_statement |
cproto-generated files More... | |
This file contains a set of functions defined to walk through the internal representation of a module and chek different things, as the number of arguments, the compatibility of the types of these arguments, ...
There is one function for each domain. Its basic principle is to walk through the internal representation by recursive calls to functions handling sub-domains.
Laurent Aniort & Fabien Coelho 1992 Print message and exit violently from flint
Definition at line 42 of file flint_walk.c.
This function checks the syntax of a call and recursively.
verifies its arguments
Definition at line 74 of file flint_walk.c.
References call_arguments, check_the_call(), flint_cons_actual_argument(), and gen_mapl().
Referenced by flint_instruction(), and flint_syntax().
void flint_cons_actual_argument | ( | list | pc | ) |
An array actual argument may have no indices
pc | c |
Definition at line 158 of file flint_walk.c.
References CAR, EXPRESSION, expression_reference(), expression_reference_p(), flint_expression(), gen_length(), and reference_indices.
Referenced by flint_call().
void flint_cons_dimension | ( | list | pc | ) |
The only global variable : the name of the current module.
extern char *current_module_name; unused and changed These two functions deal with the boundaries of finite
arrays, verifying their definition as expressions
pc | c |
Definition at line 52 of file flint_walk.c.
References CAR, DIMENSION, and flint_dimension().
void flint_cons_expression | ( | list | pc | ) |
These two functions operate on the list of expressions
pc | c |
Definition at line 150 of file flint_walk.c.
References CAR, EXPRESSION, and flint_expression().
Referenced by flint_reference().
void flint_cons_statement | ( | list | pc | ) |
pc | c |
Definition at line 269 of file flint_walk.c.
References CAR, flint_statement(), and STATEMENT.
Referenced by flint_instruction().
Definition at line 58 of file flint_walk.c.
References dimension_lower, dimension_upper, and flint_expression().
Referenced by flint_cons_dimension().
expression flint_expression | ( | expression | e | ) |
Definition at line 174 of file flint_walk.c.
References expression_syntax, and flint_syntax().
Referenced by flint_cons_actual_argument(), flint_cons_expression(), flint_dimension(), flint_range(), and flint_test().
instruction flint_instruction | ( | instruction | i | ) |
Verification of an instruction with branching according
to its subclass as defined in the data structure
Definition at line 217 of file flint_walk.c.
References check_procedure(), FATAL, flint_call(), flint_cons_statement(), flint_loop(), flint_test(), flint_unstructured(), gen_mapl(), instruction_block, instruction_call, instruction_loop, instruction_tag, instruction_test, instruction_unstructured, is_instruction_block, is_instruction_call, is_instruction_goto, is_instruction_loop, is_instruction_test, and is_instruction_unstructured.
Referenced by flint_statement().
Recursive verification of a loop as (range)+(expression)
Definition at line 186 of file flint_walk.c.
References flint_range(), flint_statement(), loop_body, and loop_range.
Referenced by flint_instruction().
This function verifies that incremented or decremented
loop(for) indices do not overflow or underflow their
limits
Definition at line 90 of file flint_walk.c.
References flint_expression(), range_increment, range_lower, and range_upper.
Referenced by flint_loop(), and flint_syntax().
A reference is used when given a function the address of.
an element instead of its value.
Definition at line 107 of file flint_walk.c.
References check_the_reference(), flint_cons_expression(), gen_mapl(), and reference_indices.
Referenced by flint_syntax().
Definition at line 278 of file flint_walk.c.
References flint_current_statement, flint_instruction(), and statement_instruction.
Referenced by flint_cons_statement(), flint_loop(), flint_test(), flint_unstructured(), and flinter().
void flint_syntax | ( | syntax | s | ) |
verification of syntaxes
branch according to the syntax subclass
Definition at line 121 of file flint_walk.c.
References FATAL, flint_call(), flint_range(), flint_reference(), is_syntax_call, is_syntax_range, is_syntax_reference, syntax_call, syntax_range, syntax_reference, and syntax_tag.
Referenced by flint_expression().
A test is taken as (expression)+(statement)+(statement)
Definition at line 200 of file flint_walk.c.
References flint_expression(), flint_statement(), test_condition, test_false, and test_true.
Referenced by flint_instruction().
void flint_unstructured | ( | unstructured | u | ) |
Definition at line 257 of file flint_walk.c.
References CONTROL_MAP, control_statement, flint_statement(), gen_free_list(), NIL, and unstructured_control.
Referenced by flint_instruction().
|
extern |
cproto-generated files
Warning! Do not modify this file that is automatically generated!
Definition at line 46 of file flint.c.
Referenced by flint_message(), flint_statement(), and flinter().