nickva opened a new issue, #4448:
URL: https://github.com/apache/couchdb/issues/4448

   https://bellard.org/quickjs/
   
   It might a be a nice fallback, at least, if SM is missing or cannot be built 
for a particular OS/arch combination.  RHEL 9 had stopped including the SM 
package, so we'd be back into building and maintained our own separate RPM for 
it. https://github.com/apache/couchdb/issues/4154
   
   Moreover, SM keeps deprecating versions fairly aggressively and new stable 
versions keep changing the C++ API, which makes it unfriendly for embedding. 
For instance: https://github.com/apache/couchdb/pull/4305
   
   QuickJS has a few nice things going for it:
   
    * Codebase is much smaller than SM
    * Built for embedding and is already a popular WASM (JS-in-JS) target.
    * Supports ES2020 syntax
    * We can include/re-compile it right into couchjs and not have to depend on 
SM 
    * It's possible to selective remove various ES6+ features when compiling it 
(Promises, Workers support etc).
    * It's possible to patch its parser to easily accept CouchDB map/reduce 
functions without the need for a full on parse-ast-transform-re-compile 
slowdown https://github.com/apache/couchdb/issues/3517


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to