new
This commit is contained in:
@@ -124,10 +124,7 @@ static JSValue js_mersenne_use_call(JSContext *js, JSValueConst new_target, int
|
||||
JS_SetOpaque(obj, mrand);
|
||||
|
||||
// Store seed as a read-only property
|
||||
JS_DefinePropertyValueStr(js, obj, "seed",
|
||||
JS_NewFloat64(js, seed),
|
||||
JS_PROP_ENUMERABLE | JS_PROP_CONFIGURABLE // Read-only (no WRITABLE)
|
||||
);
|
||||
JS_SetPropertyStr(js, obj, "seed", JS_NewFloat64(js, seed));
|
||||
|
||||
return obj;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user