V8 Project
v8::internal::BooleanBit Class Reference

#include <objects.h>

+ Inheritance diagram for v8::internal::BooleanBit:
+ Collaboration diagram for v8::internal::BooleanBit:

Static Public Member Functions

static bool get (Smi *smi, int bit_position)
 
static bool get (int value, int bit_position)
 
static Smiset (Smi *smi, int bit_position, bool v)
 
static int set (int value, int bit_position, bool v)
 

Detailed Description

Definition at line 10789 of file objects.h.

Member Function Documentation

◆ get() [1/2]

static bool v8::internal::BooleanBit::get ( int  value,
int  bit_position 
)
inlinestatic

Definition at line 10795 of file objects.h.

10795  {
10796  return (value & (1 << bit_position)) != 0;
10797  }

References v8::internal::Smi::value().

+ Here is the call graph for this function:

◆ get() [2/2]

static bool v8::internal::BooleanBit::get ( Smi smi,
int  bit_position 
)
inlinestatic

Definition at line 10791 of file objects.h.

10791  {
10792  return get(smi->value(), bit_position);
10793  }
static bool get(Smi *smi, int bit_position)
Definition: objects.h:10791

References v8::internal::Smi::value().

Referenced by v8::internal::ACCESSORS_TO_SMI(), v8::internal::AccessorInfo::all_can_read(), v8::internal::AccessorInfo::all_can_write(), v8::internal::Script::compilation_state(), v8::internal::JSArrayBuffer::is_external(), v8::internal::JSArrayBuffer::should_be_freed(), and v8::internal::SharedFunctionInfo::strict_mode().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ set() [1/2]

static int v8::internal::BooleanBit::set ( int  value,
int  bit_position,
bool  v 
)
inlinestatic

Definition at line 10803 of file objects.h.

10803  {
10804  if (v) {
10805  value |= (1 << bit_position);
10806  } else {
10807  value &= ~(1 << bit_position);
10808  }
10809  return value;
10810  }

References v8::internal::Smi::value().

+ Here is the call graph for this function:

◆ set() [2/2]

static Smi* v8::internal::BooleanBit::set ( Smi smi,
int  bit_position,
bool  v 
)
inlinestatic

Definition at line 10799 of file objects.h.

10799  {
10800  return Smi::FromInt(set(smi->value(), bit_position, v));
10801  }
static Smi * set(Smi *smi, int bit_position, bool v)
Definition: objects.h:10799
static Smi * FromInt(int value)
Definition: objects-inl.h:1321

References v8::internal::Smi::FromInt(), and v8::internal::Smi::value().

Referenced by v8::internal::BOOL_GETTER(), v8::internal::AccessorInfo::set_all_can_read(), v8::internal::AccessorInfo::set_all_can_write(), v8::internal::Script::set_compilation_state(), v8::internal::Script::set_compilation_type(), v8::internal::JSArrayBuffer::set_is_external(), v8::internal::JSArrayBuffer::set_should_be_freed(), and v8::internal::SharedFunctionInfo::set_strict_mode().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

The documentation for this class was generated from the following file: