Skip to content

Commit f910865

Browse files
feat: suggested changes / improve comments
1 parent 6192a4a commit f910865

2 files changed

Lines changed: 5 additions & 9 deletions

File tree

packages/react-native-executorch/common/rnexecutorch/host_objects/JsiConversions.h

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -369,15 +369,6 @@ inline jsi::Value getJsiValue(uint64_t val, jsi::Runtime &runtime) {
369369
return {runtime, bigInt};
370370
}
371371

372-
inline jsi::Value getJsiValue(const std::vector<int64_t> &vec,
373-
jsi::Runtime &runtime) {
374-
jsi::Array array(runtime, vec.size());
375-
for (size_t i = 0; i < vec.size(); i++) {
376-
array.setValueAtIndex(runtime, i, jsi::Value(static_cast<double>(vec[i])));
377-
}
378-
return {runtime, array};
379-
}
380-
381372
inline jsi::Value getJsiValue(int val, jsi::Runtime &runtime) {
382373
return {runtime, val};
383374
}

packages/react-native-executorch/common/rnexecutorch/metaprogramming/TypeConcepts.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,11 @@ concept DerivedFromOrSameAs = std::is_base_of_v<Base, T>;
1111
template <typename T, typename Base>
1212
concept SameAs = std::is_same_v<Base, T>;
1313

14+
template <typename T>
15+
concept HasGenerate = requires(T t) {
16+
{ &T::generate };
17+
};
18+
1419
template <typename T>
1520
concept HasGenerateFromString = requires(T t) {
1621
{ &T::generateFromString };

0 commit comments

Comments
 (0)