mirror of
				https://github.com/ruby/ruby.git
				synced 2022-11-09 12:17:21 -05:00 
			
		
		
		
	* enc/trans/utf_16_32.c (fun_so_to_utf_16be, fun_so_to_utf_16le): add
parentheses to remove warnings of gcc. * io.c (rb_io_getc): remove unused variables. * compile.c (NODE_NEXT, NODE_REDO): remove unused labels. * ext/nkf/nkf.c (rb_nkf_convert): remove unused variables. * ext/syck/rubyext.c (syck_resolver_initialize, syck_resolver_detect_implicit, syck_emitter_emit): remove unused variables. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@16061 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
		
							parent
							
								
									6f4fb0981d
								
							
						
					
					
						commit
						0a2053713b
					
				
					 7 changed files with 20 additions and 14 deletions
				
			
		
							
								
								
									
										15
									
								
								ChangeLog
									
										
									
									
									
								
							
							
						
						
									
										15
									
								
								ChangeLog
									
										
									
									
									
								
							|  | @ -1,3 +1,18 @@ | |||
| Thu Apr 17 22:20:52 2008  Yusuke Endoh  <mame@tsg.ne.jp> | ||||
| 
 | ||||
| 	* enc/trans/utf_16_32.c (fun_so_to_utf_16be, fun_so_to_utf_16le): add | ||||
| 	  parentheses to remove warnings of gcc. | ||||
| 
 | ||||
| 	* io.c (rb_io_getc): remove unused variables. | ||||
| 
 | ||||
| 	* compile.c (NODE_NEXT, NODE_REDO): remove unused labels. | ||||
| 
 | ||||
| 	* ext/nkf/nkf.c (rb_nkf_convert): remove unused variables. | ||||
| 
 | ||||
| 	* ext/syck/rubyext.c (syck_resolver_initialize, | ||||
| 	  syck_resolver_detect_implicit, syck_emitter_emit): remove unused | ||||
| 	  variables. | ||||
| 
 | ||||
| Thu Apr 17 20:12:47 2008  Yusuke Endoh  <mame@tsg.ne.jp> | ||||
| 
 | ||||
| 	* test/ruby/test_rubyoptions.rb (test_search): enable some assertions. | ||||
|  |  | |||
|  | @ -3103,7 +3103,6 @@ iseq_compile_each(rb_iseq_t *iseq, LINK_ANCHOR *ret, NODE * node, int poped) | |||
| 	} | ||||
| 	else { | ||||
| 	    rb_iseq_t *ip; | ||||
| 	  next_by_throw: | ||||
| 	    ip = iseq; | ||||
| 	    while (ip) { | ||||
| 		level = 0x8000; | ||||
|  | @ -3165,7 +3164,6 @@ iseq_compile_each(rb_iseq_t *iseq, LINK_ANCHOR *ret, NODE * node, int poped) | |||
| 	else { | ||||
| 	    rb_iseq_t *ip; | ||||
| 	    unsigned long level; | ||||
| 	  redo_by_throw: | ||||
| 	    level = 0x8000 | 0x4000; | ||||
| 	    ip = iseq; | ||||
| 	    while (ip) { | ||||
|  |  | |||
|  | @ -45,12 +45,12 @@ fun_so_to_utf_16be(const unsigned char* s, unsigned char* o) | |||
|         return 2; | ||||
|     } | ||||
|     else if ((s[0]&0xF0)==0xE0) { | ||||
|         o[0] = (s[0]<<4) | (s[1]>>2)^0x20; | ||||
|         o[0] = (s[0]<<4) | ((s[1]>>2)^0x20); | ||||
|         o[1] = (s[1]<<6) | (s[2]^0x80); | ||||
|         return 2; | ||||
|     } | ||||
|     else { | ||||
|         int w = (((s[0]&0x07)<<2) | (s[1]>>4)&0x03) - 1; | ||||
|         int w = (((s[0]&0x07)<<2) | ((s[1]>>4)&0x03)) - 1; | ||||
|         o[0] = 0xD8 | (w>>2); | ||||
|         o[1] = (w<<6) | ((s[1]&0x0F)<<2) | ((s[2]>>4)-8); | ||||
|         o[2] = 0xDC | ((s[2]>>2)&0x03); | ||||
|  | @ -106,7 +106,7 @@ fun_so_to_utf_16le(const unsigned char* s, unsigned char* o) | |||
|         return 2; | ||||
|     } | ||||
|     else { | ||||
|         int w = (((s[0]&0x07)<<2) | (s[1]>>4)&0x03) - 1; | ||||
|         int w = (((s[0]&0x07)<<2) | ((s[1]>>4)&0x03)) - 1; | ||||
|         o[1] = 0xD8 | (w>>2); | ||||
|         o[0] = (w<<6) | ((s[1]&0x0F)<<2) | ((s[2]>>4)-8); | ||||
|         o[3] = 0xDC | ((s[2]>>2)&0x03); | ||||
|  |  | |||
|  | @ -138,10 +138,6 @@ int nkf_split_options(const char *arg) | |||
| static VALUE | ||||
| rb_nkf_convert(VALUE obj, VALUE opt, VALUE src) | ||||
| { | ||||
|     rb_encoding *to_enc; | ||||
|     const char *to_e; | ||||
|     int to_encidx; | ||||
| 
 | ||||
|     reinit(); | ||||
|     StringValue(opt); | ||||
|     nkf_split_options(RSTRING_PTR(opt)); | ||||
|  |  | |||
|  | @ -884,7 +884,6 @@ syck_parser_set_resolver(VALUE self, VALUE resolver) | |||
| static VALUE | ||||
| syck_resolver_initialize(VALUE self) | ||||
| { | ||||
|     VALUE tags = rb_hash_new(); | ||||
|     rb_ivar_set(self, s_tags, rb_hash_new()); | ||||
|     return self; | ||||
| } | ||||
|  | @ -916,7 +915,6 @@ syck_resolver_use_types_at(VALUE self, VALUE hsh) | |||
| VALUE | ||||
| syck_resolver_detect_implicit(VALUE self, VALUE val) | ||||
| { | ||||
|     char *type_id; | ||||
|     return rb_str_new2( "" ); | ||||
| } | ||||
| 
 | ||||
|  | @ -1946,7 +1944,6 @@ VALUE | |||
| syck_emitter_emit(int argc, VALUE *argv, VALUE self) | ||||
| { | ||||
|     VALUE oid, proc; | ||||
|     char *anchor_name; | ||||
|     SyckEmitter *emitter; | ||||
|     struct emitter_xtra *bonus; | ||||
|     SYMID symple; | ||||
|  |  | |||
							
								
								
									
										2
									
								
								io.c
									
										
									
									
									
								
							
							
						
						
									
										2
									
								
								io.c
									
										
									
									
									
								
							|  | @ -2394,8 +2394,6 @@ static VALUE | |||
| rb_io_getc(VALUE io) | ||||
| { | ||||
|     rb_io_t *fptr; | ||||
|     int r, n; | ||||
|     VALUE str; | ||||
|     rb_encoding *enc; | ||||
| 
 | ||||
|     GetOpenFile(io, fptr); | ||||
|  |  | |||
|  | @ -759,6 +759,8 @@ x = __ENCODING__ | |||
|   end | ||||
| 
 | ||||
|   def test_void_expr_stmts_value | ||||
|     # This test checks if void contexts are warned correctly. | ||||
|     # Thus, warnings MUST NOT be suppressed. | ||||
|     $VERBOSE = true | ||||
|     x = 1 | ||||
|     assert_nil eval("x; nil") | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 mame
						mame