зеркало из https://github.com/github/ruby.git
should not check taint flag on rubyspec.
Now taint flag is obsolete and it is used fro shareaable flag. So we should not check this flag.
This commit is contained in:
Родитель
c6c241e49c
Коммит
fde136152e
|
@ -52,6 +52,7 @@
|
|||
#define FL_PROMOTED1 RBIMPL_CAST((VALUE)RUBY_FL_PROMOTED1)
|
||||
#define FL_FINALIZE RBIMPL_CAST((VALUE)RUBY_FL_FINALIZE)
|
||||
#define FL_TAINT RBIMPL_CAST((VALUE)RUBY_FL_TAINT)
|
||||
#define FL_SHAREABLE RBIMPL_CAST((VALUE)RUBY_FL_SHAREABLE)
|
||||
#define FL_UNTRUSTED RBIMPL_CAST((VALUE)RUBY_FL_UNTRUSTED)
|
||||
#define FL_SEEN_OBJ_ID RBIMPL_CAST((VALUE)RUBY_FL_SEEN_OBJ_ID)
|
||||
#define FL_EXIVAR RBIMPL_CAST((VALUE)RUBY_FL_EXIVAR)
|
||||
|
|
|
@ -5,7 +5,11 @@
|
|||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef FL_SHAREABLE
|
||||
static const VALUE VISIBLE_BITS = FL_TAINT | FL_FREEZE | ~(FL_USER0 - 1);
|
||||
#else
|
||||
static const VALUE VISIBLE_BITS = FL_FREEZE | ~(FL_USER0 - 1);
|
||||
#endif
|
||||
|
||||
#if SIZEOF_VALUE == SIZEOF_LONG
|
||||
#define VALUE2NUM(v) ULONG2NUM(v)
|
||||
|
|
|
@ -66,9 +66,9 @@ describe :rbasic, shared: true do
|
|||
obj1, obj2 = @data.call
|
||||
initial = @specs.get_flags(obj1)
|
||||
@specs.get_flags(obj2).should == initial
|
||||
@specs.set_flags(obj1, @taint | 1 << 14 | 1 << 16 | initial)
|
||||
@specs.set_flags(obj1, 1 << 14 | 1 << 16 | initial)
|
||||
@specs.copy_flags(obj2, obj1)
|
||||
@specs.get_flags(obj2).should == @taint | 1 << 14 | 1 << 16 | initial
|
||||
@specs.get_flags(obj2).should == 1 << 14 | 1 << 16 | initial
|
||||
@specs.set_flags(obj1, initial)
|
||||
@specs.copy_flags(obj2, obj1)
|
||||
@specs.get_flags(obj2).should == initial
|
||||
|
|
Загрузка…
Ссылка в новой задаче