mirror of
				https://github.com/ruby/ruby.git
				synced 2022-11-09 12:17:21 -05:00 
			
		
		
		
	parse.y: Fix the compile error
* parse.y: Fix "error: ISO C90 forbids mixed declarations and code [-Werror=declaration-after-statement]" git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@65229 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
		
							parent
							
								
									ecc627b20a
								
							
						
					
					
						commit
						2bfbec8745
					
				
					 1 changed files with 6 additions and 4 deletions
				
			
		
							
								
								
									
										10
									
								
								parse.y
									
										
									
									
									
								
							
							
						
						
									
										10
									
								
								parse.y
									
										
									
									
									
								
							| 
						 | 
				
			
			@ -3132,10 +3132,12 @@ lambda		:   {
 | 
			
		|||
			p->lex.lpar_beg = $<num>2;
 | 
			
		||||
			CMDARG_POP();
 | 
			
		||||
		    /*%%%*/
 | 
			
		||||
                        YYLTYPE loc = code_loc_gen(&@3, &@5);
 | 
			
		||||
			$$ = NEW_LAMBDA($3, $5, &loc);
 | 
			
		||||
			nd_set_line($$->nd_body, @5.end_pos.lineno);
 | 
			
		||||
			nd_set_line($$, @3.end_pos.lineno);
 | 
			
		||||
                        {
 | 
			
		||||
                            YYLTYPE loc = code_loc_gen(&@3, &@5);
 | 
			
		||||
                            $$ = NEW_LAMBDA($3, $5, &loc);
 | 
			
		||||
                            nd_set_line($$->nd_body, @5.end_pos.lineno);
 | 
			
		||||
                            nd_set_line($$, @3.end_pos.lineno);
 | 
			
		||||
                        }
 | 
			
		||||
		    /*% %*/
 | 
			
		||||
		    /*% ripper: lambda!($3, $5) %*/
 | 
			
		||||
			dyna_pop(p, $<vars>1);
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue