30 symbol.set(internalClass->engine,
s->d());
36 QString desc = QChar::fromLatin1(
'@');
37 if (argc && !argv[0].isUndefined()) {
41 desc +=
s->toQString();
48 return f->engine()->throwTypeError(
QStringLiteral(
"Symbol can't be used together with |new|."));
79 ctor->defineReadonlyProperty(
engine->id_prototype(), (
v =
this));
85 ctor->defineReadonlyProperty(
QStringLiteral(
"isConcatSpreadable"), *
engine->symbol_isConcatSpreadable());
97 defineDefaultProperty(
QStringLiteral(
"toString"), method_toString);
102 defineReadonlyConfigurableProperty(
engine->symbol_toStringTag(),
v);
109 Scoped<Symbol>
s(scope, thisObject->
as<
Symbol>());
122 Scoped<Symbol>
s(scope, thisObject->
as<
Symbol>());
129 return s->asReturnedValue();
137 return o->d()->symbol->asReturnedValue();
138 return f->engine()->throwTypeError();
\macro QT_RESTRICTED_CAST_FROM_ASCII
QString mid(qsizetype position, qsizetype n=-1) const &
ManagedType::Data * alloc(Args &&... args)
Scoped< String > ScopedString
@ Attr_ReadOnly_ButConfigurable
static const void * symbol()
static QString toString(QV4::ReturnedValue v)
GLsizei const GLfloat * v
[13]
QLatin1StringView QLatin1String
#define QStringLiteral(str)
#define DEFINE_OBJECT_VTABLE(classname)
#define DEFINE_MANAGED_VTABLE(classname)
\inmodule QtCore \reentrant
static constexpr ReturnedValue undefined()
IdentifierTable * identifierTable
MemoryManager * memoryManager
Heap::String * newString(char16_t c)
ReturnedValue throwTypeError()
ReturnedValue asReturnedValue() const
Pointer< InternalClass *, 0 > internalClass
QString toQString() const
void init(ExecutionEngine *engine)
void init(const QString &s)
Heap::Symbol * symbolForId(PropertyKey i) const
Heap::Symbol * insertSymbol(const QString &s)
static PropertyKey fromStringOrSymbol(Engine *engine, StringOrSymbol *b)
bool hasException() const
constexpr ReturnedValue asReturnedValue() const
static ReturnedValue method_keyFor(const FunctionObject *, const Value *thisObject, const Value *argv, int argc)
static ReturnedValue method_for(const FunctionObject *, const Value *thisObject, const Value *argv, int argc)
static ReturnedValue method_toString(const FunctionObject *, const Value *thisObject, const Value *argv, int argc)
void init(ExecutionEngine *engine, Object *ctor)
static ReturnedValue method_symbolToPrimitive(const FunctionObject *, const Value *thisObject, const Value *argv, int argc)
static ReturnedValue method_valueOf(const FunctionObject *, const Value *thisObject, const Value *argv, int argc)
static V4_NEEDS_DESTROY Heap::Symbol * create(ExecutionEngine *e, const QString &s)
QString descriptiveString() const
static constexpr VTable::CallAsConstructor virtualCallAsConstructor
static constexpr VTable::Call virtualCall
static constexpr Value fromInt32(int i)
Heap::String * toString(ExecutionEngine *e) const
static constexpr Value undefinedValue()