mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
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:
parent
c6c241e49c
commit
fde136152e
Notes:
git
2020-09-25 12:53:18 +09:00
3 changed files with 7 additions and 2 deletions
|
@ -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
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue