1expr(Data,Type,dot_expr(A)) --> 
    2	dot_expr(Data,Type,A).
    3
    4expr(Data,[array,string],dict_keys(A,Type)) -->
    5	dict_keys_(Data,[
    6		expr(Data,[dict,Type],A)
    7	]).
    8
    9expr(Data,string,global_replace_in_string(Str1,To_replace1,Replacement1)) -->
   10	global_replace_in_string_(Data,[
   11		parentheses_expr(Data,string,Str1),
   12		parentheses_expr(Data,string,To_replace1),
   13		parentheses_expr(Data,string,Replacement1)
   14	]).
   15expr(Data,[array,Type],sort(List)) -->
   16	sort_(Data,[
   17		parentheses_expr(Data,[array,Type],List)
   18	]).
   19
   20expr(Data,bool,type_is_string(Object)) -->
   21	type_is_string(Data,[
   22		parentheses_expr(Data,Type,Object)
   23	]).
   24
   25expr(Data,bool,type_is_bool(Object)) -->
   26	type_is_bool(Data,[
   27		parentheses_expr(Data,Type,Object)
   28	]).
   29
   30expr(Data,bool,type_is_int(Object)) -->
   31	type_is_int(Data,[
   32		parentheses_expr(Data,Type,Object)
   33	]).
   34
   35expr(Data,bool,type_is_list(Object)) -->
   36	type_is_list(Data,[
   37		parentheses_expr(Data,Type,Object)
   38	]).
   39
   40expr(Data,double,random_number) -->
   41	random_number(Data).
   42
   43dot_expr(Data,double,random_from_list(List,Type)) -->
   44	random_from_list(Data,[
   45		expr(Data,[array,Type],List)
   46	]).
   47
   48expr(Data,string,grammar_or(Var1,Var2)) -->
   49    grammar_or_(Data,[
   50		dot_expr(Data,string,Var1),
   51		expr(Data,string,Var2)
   52	]).
   53
   54expr(Data,string,grammar_and(Var1,Var2)) -->
   55    grammar_and_(Data,[
   56		dot_expr(Data,string,Var1),
   57		expr(Data,string,Var2)
   58	]).
   59
   60expr(Data,bool, or(Var1,Var2)) -->
   61    or_(Data,[
   62		dot_expr(Data,bool,Var1),
   63		expr(Data,bool,Var2)
   64	]).
   65expr(Data,bool, eager_or(Var1,Var2)) -->
   66    eager_or_(Data,[
   67		dot_expr(Data,bool,Var1),
   68		expr(Data,bool,Var2)
   69	]).
   70expr(Data,int,last_index_of(Str1,Str2)) -->
   71		last_index_of_(Data,[
   72			parentheses_expr(Data,string,Str1),
   73			parentheses_expr(Data,string,Str2)
   74		]).
   75expr(Data,int,index_of_substring(Str1,Str2)) -->
   76		index_of_substring_(Data,[
   77			parentheses_expr(Data,string,Str1),
   78			parentheses_expr(Data,string,Str2)
   79		]).
   80expr(Data,int,index_in_array(Container,Contained,Type)) -->
   81    index_in_array_(Data,[
   82		parentheses_expr(Data,[array,Type],Container),
   83        parentheses_expr(Data,Type,Contained)
   84    ]).
   85expr(Data,string,substring(Str_,Index1_,Index2_)) -->
   86        substring_(Data,[
   87			parentheses_expr(Data,string,Str_),
   88			parentheses_expr(Data,int,Index1_),
   89			parentheses_expr(Data,int,Index2_)
   90        ]).
   91expr(Data,bool,not(A1)) -->
   92        not_(Data,[
   93			parentheses_expr(Data,bool,A1)
   94		]).
   95expr(Data,bool, and(A,B)) -->
   96    and_(Data,[
   97		dot_expr(Data,bool,A),
   98		expr(Data,bool,B)
   99	]).
  100
  101expr(Data,bool, eager_and(A,B)) -->
  102    eager_and_(Data,[
  103		dot_expr(Data,bool,A),
  104		expr(Data,bool,B)
  105	]).
  106expr(Data,bool,int_not_equal(A,B)) -->
  107        int_not_equal_(Data,[
  108			dot_expr(Data,int,A),
  109			expr(Data,int,B)
  110        ]).    
  111expr(Data,bool,string_not_equal(A,B)) -->
  112        string_not_equal_(Data,[
  113			dot_expr(Data,string,A),
  114			expr(Data,string,B)
  115        ]).             
  116expr(Data,bool,greater_than(int,A,B)) -->
  117        greater_than_(Data,[
  118			expr(Data,int,A),
  119			dot_expr(Data,int,B)
  120		]).
  121
  122%universal quantifications for arrays of ints
  123%expr(Data,bool,universal_quantifications(int,A,B,English_expr)) -->
  124%        universal_quantifications_(Data,int,[
  125%			expr(Data,[array,int],A),
  126%			dot_expr(Data,int,B),
  127%			English_expr
  128%		]).
  129
  130expr(Data,bool,greater_than(double,A,B)) -->
  131        greater_than_(Data,[
  132			expr(Data,double,A),
  133			dot_expr(Data,double,B)
  134		]).
  135
  136expr(Data,bool,greater_than_or_equal(A,B)) -->
  137        greater_than_or_equal_to_(Data,[
  138			expr(Data,int,A),
  139			dot_expr(Data,int,B)
  140        ]).
  141expr(Data,bool,less_than_or_equal(A,B)) -->
  142        less_than_or_equal_to_(Data,[
  143			expr(Data,int,A),
  144			dot_expr(Data,int,B)
  145		]).
  146expr(Data,bool,less_than(A,B)) -->
  147        less_than_(Data,[
  148            expr(Data,int,A),
  149            dot_expr(Data,int,B)
  150        ]).
  151
  152expr(Data,bool,compare(string,Exp1,Exp2)) -->
  153		compare_(Data,string,[
  154                dot_expr(Data,string,Exp1),
  155                expr(Data,string,Exp2)
  156		]).
  157
  158expr(Data,string,arithmetic("+",A,B)) -->
  159        concatenate_string_(Data,[
  160			dot_expr(Data,string,A),
  161			expr(Data,string,B)
  162		]).
  163
  164%expr(Data,string,concatenate_string_to_int(A,B)) -->
  165%        concatenate_string_to_int_(Data,[
  166%			dot_expr(Data,string,A),
  167%			expr(Data,int,B)
  168%		]).
  169
  170expr(Data,int,mod(A,B)) -->
  171    mod_(Data,[
  172		dot_expr(Data,int,A),
  173        expr(Data,int,B)
  174    ]).
  175 
  176expr(Data,[array,Type],concatenate_arrays(A1,A2)) -->
  177	concatenate_arrays_(Data,[
  178		dot_expr(Data,[array,Type],A1),
  179		expr(Data,[array,Type],A2)
  180	]).
  181
  182expr(Data,bool,array_contains(Array,Contained,Type)) -->
  183	array_contains(Data,[
  184		parentheses_expr(Data,[array,Type],Array),
  185		parentheses_expr(Data,Type,Contained)
  186	]).
  187 
  188expr(Data,bool,string_contains(Str1,Str2)) -->
  189	string_contains_(Data,[
  190			parentheses_expr(Data,string,Str1),
  191			parentheses_expr(Data,string,Str2)
  192	]).
  193
  194expr(Data,Type,this(A)) -->
  195    this_(Data,[
  196		var_name_(Data,Type,A)
  197	]).
  198 
  199expr(Data,Type,access_dict(Dict,Index)) -->
  200	access_dict_(Data,[
  201		var_name_(Data,[dict,Type],Dict),
  202		Dict,
  203		expr(Data,string,Index)
  204	]).
  205         
  206expr(Data,[array,string],command_line_args) -->
  207	command_line_args_(Data).
  208
  209 
  210expr(Data,regex,new_regex(A)) -->
  211	new_regex_(Data,[
  212		expr(Data,string,A)
  213	]).
  214expr(Data,bool,regex_matches_string(Str,Reg)) -->
  215	regex_matches_string_(Data,[
  216		parentheses_expr(Data,regex,Reg),
  217		parentheses_expr(Data,string,Str)
  218	]).
  219
  220expr(Data,bool,instanceof(Expr,Type1,Type2)) -->
  221	instanceof_(Data,[
  222		parentheses_expr(Data,Type1,Expr),
  223		Type1,
  224		type(Data,Type2)
  225	])