Skip to content

Commit

Permalink
Fix typo in Value's constructor with a Symbol
Browse files Browse the repository at this point in the history
Summary:
The current JSI implementation is converting a Symbol to String when creating a jsi Value.

Changelog: [General][Fixed]

Reviewed By: neildhar

Differential Revision: D35705825

fbshipit-source-id: 3bee0a02bb77643c6a33031b4d98ac9a7e126303
  • Loading branch information
jpporto authored and facebook-github-bot committed Apr 17, 2022
1 parent 3c1a814 commit a7a0f86
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ReactCommon/jsi/jsi/jsi.h
Original file line number Diff line number Diff line change
Expand Up @@ -992,7 +992,7 @@ class JSI_EXPORT Value {

/// Copies a Symbol lvalue into a new JS value.
Value(Runtime& runtime, const Symbol& sym) : Value(SymbolKind) {
new (&data_.pointer) String(runtime.cloneSymbol(sym.ptr_));
new (&data_.pointer) Symbol(runtime.cloneSymbol(sym.ptr_));
}

/// Copies a String lvalue into a new JS value.
Expand Down

0 comments on commit a7a0f86

Please sign in to comment.