docs: public final void variable_definition() throws RecognitionException {
  		CommonTree varname=null;
  		CommonTree q=null;
  		CommonTree pattern=null;
  
  		try {
  			// src/main/resources/org/drools/compiler/lang/dsl/DSLMapWalker.g:127:5: ( ^( VT_VAR_DEF varname= LITERAL ^( VT_QUAL (q= LITERAL )? ) (pattern= VT_PATTERN )? ) )
  			// src/main/resources/org/drools/compiler/lang/dsl/DSLMapWalker.g:127:9: ^( VT_VAR_DEF varname= LITERAL ^( VT_QUAL (q= LITERAL )? ) (pattern= VT_PATTERN )? )
  			{
  			match(input,VT_VAR_DEF,FOLLOW_VT_VAR_DEF_in_variable_definition423); 
  			match(input, Token.DOWN, null); 
  			varname=(CommonTree)match(input,LITERAL,FOLLOW_LITERAL_in_variable_definition427); 
  			match(input,VT_QUAL,FOLLOW_VT_QUAL_in_variable_definition430); 
  			if ( input.LA(1)==Token.DOWN ) {
  				match(input, Token.DOWN, null); 
  				// src/main/resources/org/drools/compiler/lang/dsl/DSLMapWalker.g:127:49: (q= LITERAL )?
  				int alt13=2;
  				int LA13_0 = input.LA(1);
  				if ( (LA13_0==LITERAL) ) {
  					alt13=1;
  				}
  				switch (alt13) {
  					case 1 :
  						// src/main/resources/org/drools/compiler/lang/dsl/DSLMapWalker.g:127:49: q= LITERAL
  						{
  						q=(CommonTree)match(input,LITERAL,FOLLOW_LITERAL_in_variable_definition434); 
  						}
  						break;
  
  				}
  
  				match(input, Token.UP, null); 
  			}
  
  			// src/main/resources/org/drools/compiler/lang/dsl/DSLMapWalker.g:127:67: (pattern= VT_PATTERN )?
  			int alt14=2;
  			int LA14_0 = input.LA(1);
  			if ( (LA14_0==VT_PATTERN) ) {
  				alt14=1;
  			}
  			switch (alt14) {
  				case 1 :
  					// src/main/resources/org/drools/compiler/lang/dsl/DSLMapWalker.g:127:67: pattern= VT_PATTERN
  					{
  					pattern=(CommonTree)match(input,VT_PATTERN,FOLLOW_VT_PATTERN_in_variable_definition440); 
  					}
  					break;
  
  			}
  
  			match(input, Token.UP, null); 
  
  
  			        entry_stack.peek().variables.put((varname!=null?varname.getText():null), Integer.valueOf(0));
  
  			        if(q!=null && pattern!=null){
  			            entry_stack.peek().sentenceKeyBuffer.append("{"+(varname!=null?varname.getText():null)+":"+(q!=null?q.getText():null)+":"+(pattern!=null?pattern.getText():null)+"}");
  			        }else if(q==null && pattern!=null){
  			            entry_stack.peek().sentenceKeyBuffer.append("{"+(varname!=null?varname.getText():null)+":"+(pattern!=null?pattern.getText():null)+"}");
  			        }else{
  			            entry_stack.peek().sentenceKeyBuffer.append("{"+(varname!=null?varname.getText():null)+"}");
  			        }
  
  			        if(q == null || (!q.getText().equals("ENUM") && !q.getText().equals("CF") && 
  			                          !q.getText().equals("DATE") && !q.getText().equals("BOOLEAN"))){
  			            entry_stack.peek().keybuffer.append(pattern != null? "(" + (pattern!=null?pattern.getText():null) + ")" : "(.*?)");
  			        }else{
  			            entry_stack.peek().keybuffer.append("(.*?)");
  			        }
  			    
  			}
  
  		}
  		catch (RecognitionException re) {
  			reportError(re);
  			recover(input,re);
  		}
  		finally {
  			// do for sure before leaving
  		}
  	}