JSID_IS_SYMBOL

This article needs a technical review. How you can help.

This article covers features introduced in SpiderMonkey 38

Testing and conversion functions between a JS ID and a JS Symbol.

Syntax

bool
JSID_IS_SYMBOL(jsid id);

JS::Symbol *
JSID_TO_SYMBOL(jsid id);

jsid
SYMBOL_TO_JSID(JS::Symbol *sym);
Name Type Description
id jsid The property identifier to test or convert.
sym JS::Symbol A JS Symbol to test or convert.

Description

JSID_IS_SYMBOL tests whether a specified JS ID, id, is a JS Symbol, and returns true if it's a JS Symbol.

JSID_TO_SYMBOL converts a specified JS ID, id to a JS Symbol.

SYMBOL_TO_JSID converts a specified JS Symbol, i to a jsid.

See Also

Document Tags and Contributors

 Contributors to this page: kscarfone, arai
 Last updated by: kscarfone,