This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
gem install debugger | |
Fetching: debugger-ruby_core_source-1.2.3.gem (100%) | |
Successfully installed debugger-ruby_core_source-1.2.3 | |
Fetching: debugger-1.6.1.gem (100%) | |
Building native extensions. This could take a while... | |
ERROR: Error installing debugger: | |
ERROR: Failed to build gem native extension. | |
/home/anup/.rvm/rubies/rbx-head/bin/rbx extconf.rb | |
checking for rb_method_entry_t.called_id in method.h... no |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
rake build | |
/.rvm/rubies/ruby-2.0.0-p247/bin/ruby vm/codegen/field_extract.rb vm/builtin/basicobject.hpp vm/builtin/object.hpp vm/builtin/integer.hpp vm/builtin/fixnum.hpp vm/builtin/array.hpp vm/builtin/bignum.hpp vm/builtin/executable.hpp vm/builtin/access_variable.hpp vm/builtin/alias.hpp vm/builtin/block_environment.hpp vm/builtin/block_as_method.hpp vm/builtin/bytearray.hpp vm/builtin/io.hpp vm/builtin/channel.hpp vm/builtin/module.hpp vm/builtin/constant_table.hpp vm/builtin/class.hpp vm/builtin/compiledcode.hpp vm/builtin/data.hpp vm/builtin/dir.hpp vm/builtin/exception.hpp vm/builtin/float.hpp vm/builtin/immediates.hpp vm/builtin/iseq.hpp vm/builtin/list.hpp vm/builtin/lookuptable.hpp vm/builtin/ffi_pointer.hpp vm/builtin/methodtable.hpp vm/builtin/nativefunction.hpp vm/builtin/packed_object.hpp vm/builtin/randomizer.hpp vm/builtin/regexp.hpp vm/builtin/constantscope.hpp vm/builtin/encoding.hpp vm/builtin/string.hpp vm/builtin/symbol.hpp vm/builtin/thread.hpp vm/builtin/tuple.hpp vm/builtin/compactlook |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#On IRB | |
"\xFEhi".ascii_only? # => false | |
#io19.rb +754 | |
def check_invalid_bytes(data) | |
return if data.ascii_only? # => true | |
from_enc = data.encoding | |
to_enc = external_encoding |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#MRI | |
``` | |
"hi".encode(Encoding::UTF_16).length # => 6 | |
"hi".encode(Encoding::UTF_16) # => "\uFEFFhi" | |
``` | |
#RBX | |
``` | |
"hi".encode(Encoding::UTF_16).length # => 6 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def write(data) | |
data = String data | |
return 0 if data.length == 0 | |
ensure_open_and_writable | |
data.encode!(external_encoding) if external_encoding | |
if @sync | |
prim_write(data) | |
else |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#MRI 2.0 | |
``` | |
Encoding.default_external = Encoding::US_ASCII | |
File.expand_path("./a").encoding # => #<Encoding:UTF-8> | |
File.expand_path("./a".encode(Encoding::SHIFT_JIS)).encoding # => #<Encoding:Shift_JIS> | |
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
vm/util/timing.c: In function ‘thread_cpu_usage’: | |
vm/util/timing.c:27:3: error: aggregate value used where an integer was expected | |
vm/util/timing.c:28:3: error: aggregate value used where an integer was expected | |
Error: gcc -Ivm -Ivm/test/cxxtest -I. -Ivendor/llvm/include -Ivendor/udis86 -Ivendor/libffi/include -Ivendor/double-conversion/src -DHAVE_CONFIG_H -I. -I../../vm/capi/19/include -Ivendor/oniguruma -Ivendor/libtommath -pipe -Wall -fno-omit-frame-pointer -g -I/usr/local/include -fPIC -O2 -DHAS_EXECINFO -DHAVE_SPT_REUSEARGV -DHAVE_CLOCK_GETTIME -DHAVE_NL_LANGINFO -DHAVE_POSIX_FADVISE -DHAVE_TM_GMTOFF -DHAVE_TM_ZONE -DHAVE_TIMEZONE -DHAVE_TZNAME -DHAVE_DAYLIGHT -DHAVE_ALLOCA_H -DHAVE_STRING_H -DHAVE_SYS_TIME_H -DHAVE_SYS_TIMES_H -DHAVE_SYS_TYPES_H -DHAVE_UNISTD_H -DHAVE_STDARG_H -DSTRERROR_R_CHAR_P -I/home/anup/code/github/rubinius/vendor/llvm/Release/include -D_GNU_SOURCE -fPIC -DENABLE_LLVM -Wno-unused-function -Werror -DRBX_PROFILER -D__STDC_LIMIT_MACROS -D__STDC_CONSTANT_MACROS -D_LARGEFILE_SOURCE - |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Ruby 2.0 | |
:"\xC3\x9Cber".encoding # => #<Encoding:UTF-8> | |
:a.encoding # => #<Encoding:US-ASCII> | |
#Rbx | |
:"\xC3\x9Cber".encoding # => #<Encoding:US-ASCII> | |
:a.encoding # => #<Encoding:US-ASCII> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/kernel/common/regexp19.rb b/kernel/common/regexp19.rb | |
index 6af0dcf..07c03fd 100644 | |
--- a/kernel/common/regexp19.rb | |
+++ b/kernel/common/regexp19.rb | |
@@ -116,12 +116,14 @@ class Regexp | |
source.encoding | |
end | |
- def self.convert(pattern) | |
- return pattern if pattern.kind_of? Regexp |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/kernel/common/regexp19.rb b/kernel/common/regexp19.rb | |
index 8496d78..4459921 100644 | |
--- a/kernel/common/regexp19.rb | |
+++ b/kernel/common/regexp19.rb | |
@@ -116,26 +116,6 @@ class Regexp | |
source.encoding | |
end | |
- def self.compatible_encodings(*patterns) | |
- ascii = [] |
NewerOlder