Comments (4)
Is this issue still available?
from boa.
@MartiPresa Sure! Let me assign it to you.
from boa.
As a small guidance, the enum you need to work on is here:
boa/core/engine/src/value/mod.rs
Lines 62 to 81 in 848103a
Ideally, the new repr of JsValue
would be:
#[derive(Trace, Finalize, Debug, Clone)]
struct JsValue {
inner: ValueRepr
}
#[derive(Finalize, Debug, Clone)]
enum ValueRepr {
Null,
Undefined,
/* ... rest of the variants ... */
}
Then, JsValue
would need to expose a method to get an enum of the inner variant:
impl JsValue {
pub variant(&self) -> JsValueVariant<'_> {
/// Convert from &ValueRepr to JsValueVariant<'_>
}
}
The rest is fixing all the compilation errors related to the new API, like replacing direct matches of JsValue
variables to calls to variant()
which match on JsValueVariant
.
from boa.
from boa.
Related Issues (20)
- Possible Incompleteness HOT 1
- Tracking issue for the `Intl` builtin object HOT 1
- Intl: Implement `supportedLocalesOf` for services
- Intl: Extract implementation into a separate crate
- Intl: Remove hacks to get the supported locales of a service HOT 1
- Add backtraces to errors HOT 2
- Explore other storage methods for our test results HOT 12
- custom `JsValue` for better embed HOT 2
- Function.prototyp.toString only returns a fixed `[native code]` string
- Relative imports in SimpleModuleLoader fail to resolve HOT 4
- `Context::get_active_script_or_module` should return a script or module when using import in a generator HOT 1
- Simplifying Function Binding HOT 4
- Array.prototype.at
- Implement `console.groupCollapsed()` method
- Implement `console.table()` method HOT 2
- Implement `console.profile()` and `console.profileEnd()` methods HOT 1
- Implement `console.trace()` method
- Implement `console.timeStamp()` methods HOT 2
- Add Boa Matrix space to the repo HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from boa.