SlideShare a Scribd company logo
1 of 108
Download to read offline
Rust JavaScript
Ingvar Stepanyan
@RReverser
Wait but why
JavaScript:
true cross-platform target
JavaScript:
true cross-platform target
JavaScript:
true cross-platform target
JavaScript:
true cross-platform target
JavaScript:
true cross-platform target
JavaScript:
true cross-platform target
JavaScript:
true cross-platform target
JavaScript:
true cross-platform target
JavaScript:
true cross-platform target
Wait but how
C/C++ CFG/SSA
LLVM
bitcode
Native
objects
Native
executable
Clang (LLVM)
C/C++ CFG/SSA 
LLVM
bitcode
JavaScript /
WASM
Emscripten (LLVM)
Rust CFG/SSA
LLVM
bitcode
Native
objects
Native
executable
Rust (LLVM)
Emscripten + Rust
Rust CFG/SSA
LLVM
bitcode
Native
objects
Native
executable
C/C++ CFG/SSA 
LLVM
bitcode
JavaScript /
WASM
Emscripten + Rust
Rust CFG/SSA
LLVM
bitcode
Native
objects
Native
executable
C/C++ CFG/SSA 
LLVM
bitcode
JavaScript /
WASM
Emscripten + Rust
Rust CFG/SSA
LLVM
bitcode
C/C++ CFG/SSA 
LLVM
bitcode
JavaScript /
WASM
Hell o'world
// hello.rs
fn main() {
println!("Hello, world");
}
$ rustc --target=asmjs-unknown-emscripten hello.rs
$ node hello.js
Hello, world
Exporting functions
#[no_mangle]
pub extern fn add_integers(x: i32, y: i32) -> i32 {
return x + y;
}
Exporting functions
#[no_mangle]
pub extern fn add_integers(x: i32, y: i32) -> i32 {
return x + y;
}
fn main() {}
$ rustc --target=asmjs-unknown-emscripten hello.rs
$ node
> require('./hello')
$
Exporting functions
#![feature(link_args)]
#[no_mangle]
pub extern fn add_integers(x: i32, y: i32) -> i32 {
return x + y;
}
#[link_args = "-s NO_EXIT_RUNTIME=1"]
extern {}
fn main() {}
Exporting functions
#[no_mangle]
pub extern fn add_integers(x: i32, y: i32) -> i32 {
return x + y;
}
extern {
fn emscripten_exit_with_live_runtime();
}
fn main() {
unsafe {
emscripten_exit_with_live_runtime();
}
}
$ rustc --target=asmjs-unknown-emscripten hello.rs
$ node
> require('./hello')
exit(0) implicitly called by end of main(), but
noExitRuntime, so not exiting the runtime (you can
use emscripten_force_exit, if you want to force a
true shutdown)
[Emscripten Module object]
> require('./hello')._add_integers(10, 20)
30
Exporting functions
$ emcc ... "hello.0.o" "-o" "hello.js" "-s"
"EXPORTED_FUNCTIONS=["_add_integers","_main",
"_rust_eh_personality"]" ...
Exporting functions
var real__add_integers = asm["_add_integers"];
asm["_add_integers"] = function() {
assert(runtimeInitialized, 'you need to wait for the runtime
to be ready (e.g. wait for main() to be called)');
assert(!runtimeExited, 'the runtime was exited (use
NO_EXIT_RUNTIME to keep it alive after main() exits)');
return real__add_integers.apply(null, arguments);
};
Generated code (asm.js)
function _add_integers($0,$1) {
$0 = $0|0;
$1 = $1|0;
var $$arith = 0, $$ispos = 0, $$negcheck = 0, $$negtemp = 0, $$poscheck = 0, $
$postemp = 0, $$select = 0, $2 = 0, label = 0, sp = 0;
sp = STACKTOP;
$$arith = (($0) + ($1))|0;
$$postemp = (($0) + -2147483648)|0;
$$negtemp = (($0) + 2147483647)|0;
$$poscheck = ($$arith|0)<($$postemp|0);
$$negcheck = ($$arith|0)>($$negtemp|0);
$$ispos = ($0|0)>=(0);
$$select = $$ispos ? $$poscheck : $$negcheck;
$2 = $$select;
if ($2) {
__ZN4core9panicking5panic17h0c8c35aaab94c092E(2160);
// unreachable;
} else {
return ($$arith|0);
}
return (0)|0;
}
Optimized code (asm.js)
function _add_integers($0, $1) {
$0 = $0 | 0;
$1 = $1 | 0;
return $1 + $0 | 0; //@line 47
}
Optimized code (WASM)
(func $_add_integers (param $0 i32) (param $1 i32)
(result i32)
(i32.add
(get_local $1)
(get_local $0)
)
)
asm.js <-> wasm
x+y|0
(i32.add (get_local $x)
(get_local $y))
+(x+y)
(i32.add (get_local $x)
(get_local $y))
f()|0 (call $f)
HEAP32[ptr>>2]|0
(i32.load (get_local
$ptr))
Memory model
var HEAP8 = new global.Int8Array(buffer);
var HEAP16 = new global.Int16Array(buffer);
var HEAP32 = new global.Int32Array(buffer);
var HEAPU8 = new global.Uint8Array(buffer);
var HEAPU16 = new global.Uint16Array(buffer);
var HEAPU32 = new global.Uint32Array(buffer);
var HEAPF32 = new global.Float32Array(buffer);
var HEAPF64 = new global.Float64Array(buffer);
Memory model
Calling JavaScript
#include <emscripten.h>
int main() {
EM_ASM(
alert("who doesn't like popups?");
);
return 0;
}
Calling JavaScript
// system/include/emscripten/em_asm.h
#define EM_ASM(...) emscripten_asm_const(#__VA_ARGS__)
#define EM_ASM_(code, ...)
emscripten_asm_const_int(#code, __VA_ARGS__)
...
Calling JavaScript
emscripten_asm_const: true,
emscripten_asm_const_int: true,
emscripten_asm_const_double: true,
Calling JavaScript
function _main() {
var label = 0, sp = 0;
sp = STACKTOP;
_emscripten_asm_const_v(0);
return 0;
}
Calling JavaScript
var ASM_CONSTS = [function() {
alert("who doesn't like popups?");
}];
function _emscripten_asm_const_v(code) {
return ASM_CONSTS[code]();
}
Calling JavaScript
extern {
fn emscripten_asm_const(code: &str, ...);
}
Calling JavaScript
extern {
fn emscripten_asm_const(code: *const u8, ...);
}
Calling JavaScript
unsafe {
emscripten_asm_const_int(b"alert("who doesn't like
popups?");");
}
Calling JavaScript
unsafe {
emscripten_asm_const_int(b"alert("who doesn't like
popups?");".as_ptr());
}
Calling JavaScript
unsafe {
emscripten_asm_const_int(b"alert("who doesn't like
popups?");" as *const u8);
}
Calling JavaScript
unsafe {
emscripten_asm_const_int(b"alert("who doesn't like
popups?");0" as *const u8);
}
Calling JavaScript
macro_rules! js {
($expr:expr $(,$arg:expr)*) => (unsafe {
emscripten_asm_const(
concat!(stringify!($expr), "0")
as *const str
as *const u8
)
})
}
Calling JavaScript
js! {
alert("who doesn't like popups?");
}
Calling JavaScript
But what about fancy types
Embind
C++ magic
#include <emscripten/bind.h>
using namespace emscripten;
class MyClass {
public:
MyClass(int x) : x(x) {}
int getX() const { return x; }
void setX(int x_) { x = x_; }
private:
int x;
};
// Binding code
EMSCRIPTEN_BINDINGS(my_class_example) {
class_<MyClass>("MyClass")
.constructor<int>()
.property("x", &MyClass::getX, &MyClass::setX)
;
}
$ emcc --bind hello.cpp -o hello.js
> module = require('./hello')
[Emscripten Module object]
> myObj = new module.MyClass(10)
MyClass {}
> myObj.x
10
> myObj.$$.ptr
5247384
> module.HEAP32[myObj.$$.ptr >> 2]
10
Embind
C++ magic
EMSCRIPTEN_ALWAYS_INLINE explicit class_(const char* name) {
using namespace internal;
BaseSpecifier::template verify<ClassType>();
auto _getActualType = &getActualType<ClassType>;
auto upcast = BaseSpecifier::template getUpcaster<ClassType>();
auto downcast = BaseSpecifier::template getDowncaster<ClassType>();
auto destructor = &raw_destructor<ClassType>;
_embind_register_class(
TypeID<ClassType>::get(),
TypeID<AllowedRawPointer<ClassType>>::get(),
TypeID<AllowedRawPointer<const ClassType>>::get(),
BaseSpecifier::get(),
getSignature(_getActualType),
reinterpret_cast<GenericFunction>(_getActualType),
getSignature(upcast),
reinterpret_cast<GenericFunction>(upcast),
getSignature(downcast),
reinterpret_cast<GenericFunction>(downcast),
name,
getSignature(destructor),
reinterpret_cast<GenericFunction>(destructor));
}
EMSCRIPTEN_ALWAYS_INLINE explicit class_(const char* name) {
using namespace internal;
BaseSpecifier::template verify<ClassType>();
auto _getActualType = &getActualType<ClassType>;
auto upcast = BaseSpecifier::template getUpcaster<ClassType>();
auto downcast = BaseSpecifier::template getDowncaster<ClassType>();
auto destructor = &raw_destructor<ClassType>;
_embind_register_class(
TypeID<ClassType>::get(),
TypeID<AllowedRawPointer<ClassType>>::get(),
TypeID<AllowedRawPointer<const ClassType>>::get(),
BaseSpecifier::get(),
getSignature(_getActualType),
reinterpret_cast<GenericFunction>(_getActualType),
getSignature(upcast),
reinterpret_cast<GenericFunction>(upcast),
getSignature(downcast),
reinterpret_cast<GenericFunction>(downcast),
name,
getSignature(destructor),
reinterpret_cast<GenericFunction>(destructor));
}
Reverse-engineering
FTW
// Implemented in JavaScript. Don't call these directly.
extern "C" {
...
void _embind_register_class(
...
);
...
}
// Implemented in JavaScript. Don't call these directly.
extern "C" {
...
void _embind_register_class(
TYPEID classType,
TYPEID pointerType,
TYPEID constPointerType,
TYPEID baseClassType,
const char* getActualTypeSignature,
GenericFunction getActualType,
const char* upcastSignature,
GenericFunction upcast,
const char* downcastSignature,
GenericFunction downcast,
const char* className,
const char* destructorSignature,
GenericFunction destructor);
...
}
#![feature(core_intrinsics)]
::std::intrinsics::type_id::<T>()
#![feature(core_intrinsics)]
::std::intrinsics::type_id::<T>() as u32
// Implemented in JavaScript. Don't call these directly.
extern "C" {
...
void _embind_register_class(
TYPEID classType,
TYPEID pointerType,
TYPEID constPointerType,
TYPEID baseClassType,
const char* getActualTypeSignature,
GenericFunction getActualType,
const char* upcastSignature,
GenericFunction upcast,
const char* downcastSignature,
GenericFunction downcast,
const char* className,
const char* destructorSignature,
GenericFunction destructor);
...
}
extern fn get_actual_type<T: 'static>(arg: *const void) -> u32 {
unsafe {
type_id::<T>()
}
}
// Implemented in JavaScript. Don't call these directly.
extern "C" {
...
void _embind_register_class(
TYPEID classType,
TYPEID pointerType,
TYPEID constPointerType,
TYPEID baseClassType,
const char* getActualTypeSignature,
GenericFunction getActualType,
const char* upcastSignature,
GenericFunction upcast,
const char* downcastSignature,
GenericFunction downcast,
const char* className,
const char* destructorSignature,
GenericFunction destructor);
...
}
void smth(int x, float y, const char *z);
void smth(int x, float y, const char *z);
"vifi"
// Implemented in JavaScript. Don't call these directly.
extern "C" {
...
void _embind_register_class(
TYPEID classType,
TYPEID pointerType,
TYPEID constPointerType,
TYPEID baseClassType,
const char* getActualTypeSignature,
GenericFunction getActualType,
const char* upcastSignature,
GenericFunction upcast,
const char* downcastSignature,
GenericFunction downcast,
const char* className,
const char* destructorSignature,
GenericFunction destructor);
...
}
// Implemented in JavaScript. Don't call these directly.
extern "C" {
...
void _embind_register_class(
TYPEID classType,
TYPEID pointerType,
TYPEID constPointerType,
TYPEID baseClassType,
const char* getActualTypeSignature,
GenericFunction getActualType,
const char* upcastSignature,
GenericFunction upcast,
const char* downcastSignature,
GenericFunction downcast,
const char* className,
const char* destructorSignature,
GenericFunction destructor);
...
}
::std::intrinsics::type_name::<T>()
CString::new(::std::intrinsics::type_name::<T>())
.unwrap()
.as_ptr(),
// Implemented in JavaScript. Don't call these directly.
extern "C" {
...
void _embind_register_class(
TYPEID classType,
TYPEID pointerType,
TYPEID constPointerType,
TYPEID baseClassType,
const char* getActualTypeSignature,
GenericFunction getActualType,
const char* upcastSignature,
GenericFunction upcast,
const char* downcastSignature,
GenericFunction downcast,
const char* className,
const char* destructorSignature,
GenericFunction destructor);
...
}
extern fn destructure<T: 'static>(arg: *mut void) {
unsafe {
Box::from_raw(arg as *mut T);
}
}
// Implemented in JavaScript. Don't call these directly.
extern "C" {
...
void _embind_register_class(
TYPEID classType,
TYPEID pointerType,
TYPEID constPointerType,
TYPEID baseClassType,
const char* getActualTypeSignature,
GenericFunction getActualType,
const char* upcastSignature,
GenericFunction upcast,
const char* downcastSignature,
GenericFunction downcast,
const char* className,
const char* destructorSignature,
GenericFunction destructor);
...
}
unsafe {
_embind_register_class(
type_id::<T>(),
type_id::<*mut T>(),
type_id::<*const T>(),
null(),
b"ii0".as_ptr(),
get_actual_type::<T>,
b"v0".as_ptr(),
noop,
b"v0".as_ptr(),
noop,
CString::new(type_name::<T>()).unwrap().as_ptr(),
b"vi0".as_ptr(),
destructure::<T>
)
}
unsafe {
_embind_register_class(
type_id::<T>(),
type_id::<*mut T>(),
type_id::<*const T>(),
null(),
cstr!("ii"),
get_actual_type::<T>,
cstr!("v"),
noop,
cstr!("v"),
noop,
CString::new(type_name::<T>()).unwrap().as_ptr(),
cstr!("vi"),
destructure::<T>
)
}
void _embind_register_class_constructor(
TYPEID classType,
unsigned argCount,
const TYPEID argTypes[],
const char* invokerSignature,
GenericFunction invoker,
GenericFunction constructor);
extern {
fn _embind_register_class_constructor(
cls_type: TypeId,
arg_count: usize,
arg_types: *const TypeId,
invoker_signature: CStr,
invoker: extern fn (
fn () -> Box<void>
) -> *mut void,
ctor: fn () -> Box<void>
);
}
#[allow(improper_ctypes)]
extern {
fn _embind_register_class_constructor(
cls_type: TypeId,
arg_count: usize,
arg_types: *const TypeId,
invoker_signature: CStr,
invoker: extern fn (
fn () -> Box<void>
) -> *mut void,
ctor: fn () -> Box<void>
);
}
extern fn invoker(f: fn () -> Box<void>) -> *mut void {
Box::into_raw(f())
}
unsafe {
let arg_types = [type_id::<*mut T>()];
_embind_register_class_constructor(
type_id::<T>(),
arg_types.len(),
arg_types.as_ptr(),
cstr!("ii"),
invoker,
::std::mem::transmute(
Box::<T>::default as fn () -> Box<_>
)
)
}
register_class::<MyStruct>();
register_class_default_ctor::<MyStruct>();
_embind_register_*
• void
• bool
• integer
• float
• std_string
• std_wstring
• memory_view
• function
• class
• enum
• smart_ptr
• ...
JavaScript static libraries
mergeInto(LibraryManager.library, {
my_js: function() {
alert('hi');
},
});
#[link_args = "--js-library rustlib.js"]
extern {
fn my_js();
}
mergeInto(LibraryManager.library, {
_embind_register_rust_string__deps: ['$registerType'],
_embind_register_rust_string: function(rawType) {
registerType(rawType, {
name: "&str",
'argPackAdvance': 8,
'readValueFromPointer': function (pointer) {
pointer >>= 2;
var length = HEAPU32[pointer + 1];
pointer = HEAPU32[pointer];
return Pointer_stringify(pointer, length);
}
});
},
})
#[link_args = "--js-library rustlib.js"]
extern {
fn _embind_register_rust_string(type_id: u32);
}
...
_embind_register_rust_string(type_id::<&str>());
Garbage collection
Garbage collection
window [1]
5
Garbage collection
window [2]
5
_emval_incref (aka Clone)
Garbage collection
window [2] "document"
5 6
_emval_take_value(...)
aka
Val::from("document").handle
Garbage collection
window [2] "document" document
5 6 7
_emval_get_property(...)
aka
global.get("document").handle
Garbage collection
window [1] document
5 7
_emval_decref(...)
aka
Drop for "document"
and
Drop for window
Serde + Emscripten
#[derive(Serialize)]
struct S {
x: &'static str,
y: u64,
z: [f64; 2]
}
let s = S {
x: "hello, world",
y: 42,
z: [123.456, 789.]
};
let val = s.serialize(Serializer).unwrap();
{
x: "hello, world",
y: 42,
z: [123.456, 789]
}
Speed (2.8M JSON)
native JSON.parse
serde-json
0ms 25ms 50ms 75ms 100ms
Speed (2.8M JSON)
via JSON
embind
0ms 27.5ms 55ms 82.5ms 110ms
Useful links
• https://github.com/RReverser/asmjs-experiments - safe
bindings for Embind
• https://kripken.github.io/emscripten-site/docs/
api_reference/emscripten.h.html - Emscripten APIs
• https://github.com/rust-lang/rust/pull/41409 - allow
linking JS libraries as normal libs
• https://github.com/rust-lang/cargo/pull/3954 - let Cargo
run binaries, tests, benchmarks on Emscripten target
via Node.js
unsafe {
get_questions()
}
Ingvar Stepanyan
@RReverser

More Related Content

What's hot

ES6 - Next Generation Javascript
ES6 - Next Generation JavascriptES6 - Next Generation Javascript
ES6 - Next Generation JavascriptRamesh Nair
 
Esprima - What is that
Esprima - What is thatEsprima - What is that
Esprima - What is thatAbhijeet Pawar
 
PHP 7 – What changed internally? (Forum PHP 2015)
PHP 7 – What changed internally? (Forum PHP 2015)PHP 7 – What changed internally? (Forum PHP 2015)
PHP 7 – What changed internally? (Forum PHP 2015)Nikita Popov
 
HelsinkiJS meet-up. Dmitry Soshnikov - ECMAScript 6
HelsinkiJS meet-up. Dmitry Soshnikov - ECMAScript 6HelsinkiJS meet-up. Dmitry Soshnikov - ECMAScript 6
HelsinkiJS meet-up. Dmitry Soshnikov - ECMAScript 6Dmitry Soshnikov
 
Xlab #1: Advantages of functional programming in Java 8
Xlab #1: Advantages of functional programming in Java 8Xlab #1: Advantages of functional programming in Java 8
Xlab #1: Advantages of functional programming in Java 8XSolve
 
LetSwift RxSwift 시작하기
LetSwift RxSwift 시작하기LetSwift RxSwift 시작하기
LetSwift RxSwift 시작하기Wanbok Choi
 
Explaining ES6: JavaScript History and What is to Come
Explaining ES6: JavaScript History and What is to ComeExplaining ES6: JavaScript History and What is to Come
Explaining ES6: JavaScript History and What is to ComeCory Forsyth
 
Rails-like JavaScript Using CoffeeScript, Backbone.js and Jasmine
Rails-like JavaScript Using CoffeeScript, Backbone.js and JasmineRails-like JavaScript Using CoffeeScript, Backbone.js and Jasmine
Rails-like JavaScript Using CoffeeScript, Backbone.js and JasmineRaimonds Simanovskis
 
連邦の白いヤツ 「Objective-C」
連邦の白いヤツ 「Objective-C」連邦の白いヤツ 「Objective-C」
連邦の白いヤツ 「Objective-C」matuura_core
 
The state of your own hypertext preprocessor
The state of your own hypertext preprocessorThe state of your own hypertext preprocessor
The state of your own hypertext preprocessorAlessandro Nadalin
 
Don't Be Afraid of Abstract Syntax Trees
Don't Be Afraid of Abstract Syntax TreesDon't Be Afraid of Abstract Syntax Trees
Don't Be Afraid of Abstract Syntax TreesJamund Ferguson
 
Static Optimization of PHP bytecode (PHPSC 2017)
Static Optimization of PHP bytecode (PHPSC 2017)Static Optimization of PHP bytecode (PHPSC 2017)
Static Optimization of PHP bytecode (PHPSC 2017)Nikita Popov
 
Electrify your code with PHP Generators
Electrify your code with PHP GeneratorsElectrify your code with PHP Generators
Electrify your code with PHP GeneratorsMark Baker
 
Mongoskin - Guilin
Mongoskin - GuilinMongoskin - Guilin
Mongoskin - GuilinJackson Tian
 
FalsyValues. Dmitry Soshnikov - ECMAScript 6
FalsyValues. Dmitry Soshnikov - ECMAScript 6FalsyValues. Dmitry Soshnikov - ECMAScript 6
FalsyValues. Dmitry Soshnikov - ECMAScript 6Dmitry Soshnikov
 
PHP 7 – What changed internally?
PHP 7 – What changed internally?PHP 7 – What changed internally?
PHP 7 – What changed internally?Nikita Popov
 

What's hot (20)

ES6 - Next Generation Javascript
ES6 - Next Generation JavascriptES6 - Next Generation Javascript
ES6 - Next Generation Javascript
 
JavaScript ES6
JavaScript ES6JavaScript ES6
JavaScript ES6
 
Esprima - What is that
Esprima - What is thatEsprima - What is that
Esprima - What is that
 
PHP 7 – What changed internally? (Forum PHP 2015)
PHP 7 – What changed internally? (Forum PHP 2015)PHP 7 – What changed internally? (Forum PHP 2015)
PHP 7 – What changed internally? (Forum PHP 2015)
 
HelsinkiJS meet-up. Dmitry Soshnikov - ECMAScript 6
HelsinkiJS meet-up. Dmitry Soshnikov - ECMAScript 6HelsinkiJS meet-up. Dmitry Soshnikov - ECMAScript 6
HelsinkiJS meet-up. Dmitry Soshnikov - ECMAScript 6
 
Xlab #1: Advantages of functional programming in Java 8
Xlab #1: Advantages of functional programming in Java 8Xlab #1: Advantages of functional programming in Java 8
Xlab #1: Advantages of functional programming in Java 8
 
LetSwift RxSwift 시작하기
LetSwift RxSwift 시작하기LetSwift RxSwift 시작하기
LetSwift RxSwift 시작하기
 
Explaining ES6: JavaScript History and What is to Come
Explaining ES6: JavaScript History and What is to ComeExplaining ES6: JavaScript History and What is to Come
Explaining ES6: JavaScript History and What is to Come
 
Rails-like JavaScript Using CoffeeScript, Backbone.js and Jasmine
Rails-like JavaScript Using CoffeeScript, Backbone.js and JasmineRails-like JavaScript Using CoffeeScript, Backbone.js and Jasmine
Rails-like JavaScript Using CoffeeScript, Backbone.js and Jasmine
 
連邦の白いヤツ 「Objective-C」
連邦の白いヤツ 「Objective-C」連邦の白いヤツ 「Objective-C」
連邦の白いヤツ 「Objective-C」
 
JavaScript on the GPU
JavaScript on the GPUJavaScript on the GPU
JavaScript on the GPU
 
The state of your own hypertext preprocessor
The state of your own hypertext preprocessorThe state of your own hypertext preprocessor
The state of your own hypertext preprocessor
 
Don't Be Afraid of Abstract Syntax Trees
Don't Be Afraid of Abstract Syntax TreesDon't Be Afraid of Abstract Syntax Trees
Don't Be Afraid of Abstract Syntax Trees
 
Static Optimization of PHP bytecode (PHPSC 2017)
Static Optimization of PHP bytecode (PHPSC 2017)Static Optimization of PHP bytecode (PHPSC 2017)
Static Optimization of PHP bytecode (PHPSC 2017)
 
Rails on Oracle 2011
Rails on Oracle 2011Rails on Oracle 2011
Rails on Oracle 2011
 
Electrify your code with PHP Generators
Electrify your code with PHP GeneratorsElectrify your code with PHP Generators
Electrify your code with PHP Generators
 
Mongoskin - Guilin
Mongoskin - GuilinMongoskin - Guilin
Mongoskin - Guilin
 
ES2015 workflows
ES2015 workflowsES2015 workflows
ES2015 workflows
 
FalsyValues. Dmitry Soshnikov - ECMAScript 6
FalsyValues. Dmitry Soshnikov - ECMAScript 6FalsyValues. Dmitry Soshnikov - ECMAScript 6
FalsyValues. Dmitry Soshnikov - ECMAScript 6
 
PHP 7 – What changed internally?
PHP 7 – What changed internally?PHP 7 – What changed internally?
PHP 7 – What changed internally?
 

Similar to Rust ⇋ JavaScript

MiamiJS - The Future of JavaScript
MiamiJS - The Future of JavaScriptMiamiJS - The Future of JavaScript
MiamiJS - The Future of JavaScriptCaridy Patino
 
From mysql to MongoDB(MongoDB2011北京交流会)
From mysql to MongoDB(MongoDB2011北京交流会)From mysql to MongoDB(MongoDB2011北京交流会)
From mysql to MongoDB(MongoDB2011北京交流会)Night Sailer
 
Refactoring to Macros with Clojure
Refactoring to Macros with ClojureRefactoring to Macros with Clojure
Refactoring to Macros with ClojureDmitry Buzdin
 
Introdução ao Perl 6
Introdução ao Perl 6Introdução ao Perl 6
Introdução ao Perl 6garux
 
EcmaScript unchained
EcmaScript unchainedEcmaScript unchained
EcmaScript unchainedEduard Tomàs
 
Good Evils In Perl (Yapc Asia)
Good Evils In Perl (Yapc Asia)Good Evils In Perl (Yapc Asia)
Good Evils In Perl (Yapc Asia)Kang-min Liu
 
Real life-coffeescript
Real life-coffeescriptReal life-coffeescript
Real life-coffeescriptDavid Furber
 
JavaScript for PHP developers
JavaScript for PHP developersJavaScript for PHP developers
JavaScript for PHP developersStoyan Stefanov
 
JavaScript 2016 for C# Developers
JavaScript 2016 for C# DevelopersJavaScript 2016 for C# Developers
JavaScript 2016 for C# DevelopersRick Beerendonk
 
Wheels we didn't re-invent: Perl's Utility Modules
Wheels we didn't re-invent: Perl's Utility ModulesWheels we didn't re-invent: Perl's Utility Modules
Wheels we didn't re-invent: Perl's Utility ModulesWorkhorse Computing
 
PHP tips and tricks
PHP tips and tricks PHP tips and tricks
PHP tips and tricks Damien Seguy
 
Building Testable PHP Applications
Building Testable PHP ApplicationsBuilding Testable PHP Applications
Building Testable PHP Applicationschartjes
 
TypeScript Introduction
TypeScript IntroductionTypeScript Introduction
TypeScript IntroductionDmitry Sheiko
 
Can't Miss Features of PHP 5.3 and 5.4
Can't Miss Features of PHP 5.3 and 5.4Can't Miss Features of PHP 5.3 and 5.4
Can't Miss Features of PHP 5.3 and 5.4Jeff Carouth
 
Php my sql - functions - arrays - tutorial - programmerblog.net
Php my sql - functions - arrays - tutorial - programmerblog.netPhp my sql - functions - arrays - tutorial - programmerblog.net
Php my sql - functions - arrays - tutorial - programmerblog.netProgrammer Blog
 

Similar to Rust ⇋ JavaScript (20)

Groovy
GroovyGroovy
Groovy
 
MiamiJS - The Future of JavaScript
MiamiJS - The Future of JavaScriptMiamiJS - The Future of JavaScript
MiamiJS - The Future of JavaScript
 
From mysql to MongoDB(MongoDB2011北京交流会)
From mysql to MongoDB(MongoDB2011北京交流会)From mysql to MongoDB(MongoDB2011北京交流会)
From mysql to MongoDB(MongoDB2011北京交流会)
 
Refactoring to Macros with Clojure
Refactoring to Macros with ClojureRefactoring to Macros with Clojure
Refactoring to Macros with Clojure
 
PHPSpec BDD for PHP
PHPSpec BDD for PHPPHPSpec BDD for PHP
PHPSpec BDD for PHP
 
Introdução ao Perl 6
Introdução ao Perl 6Introdução ao Perl 6
Introdução ao Perl 6
 
EcmaScript unchained
EcmaScript unchainedEcmaScript unchained
EcmaScript unchained
 
Good Evils In Perl (Yapc Asia)
Good Evils In Perl (Yapc Asia)Good Evils In Perl (Yapc Asia)
Good Evils In Perl (Yapc Asia)
 
Real life-coffeescript
Real life-coffeescriptReal life-coffeescript
Real life-coffeescript
 
JavaScript for PHP developers
JavaScript for PHP developersJavaScript for PHP developers
JavaScript for PHP developers
 
JavaScript 2016 for C# Developers
JavaScript 2016 for C# DevelopersJavaScript 2016 for C# Developers
JavaScript 2016 for C# Developers
 
Wheels we didn't re-invent: Perl's Utility Modules
Wheels we didn't re-invent: Perl's Utility ModulesWheels we didn't re-invent: Perl's Utility Modules
Wheels we didn't re-invent: Perl's Utility Modules
 
Message in a bottle
Message in a bottleMessage in a bottle
Message in a bottle
 
Modern Perl
Modern PerlModern Perl
Modern Perl
 
Wakanday JS201 Best Practices
Wakanday JS201 Best PracticesWakanday JS201 Best Practices
Wakanday JS201 Best Practices
 
PHP tips and tricks
PHP tips and tricks PHP tips and tricks
PHP tips and tricks
 
Building Testable PHP Applications
Building Testable PHP ApplicationsBuilding Testable PHP Applications
Building Testable PHP Applications
 
TypeScript Introduction
TypeScript IntroductionTypeScript Introduction
TypeScript Introduction
 
Can't Miss Features of PHP 5.3 and 5.4
Can't Miss Features of PHP 5.3 and 5.4Can't Miss Features of PHP 5.3 and 5.4
Can't Miss Features of PHP 5.3 and 5.4
 
Php my sql - functions - arrays - tutorial - programmerblog.net
Php my sql - functions - arrays - tutorial - programmerblog.netPhp my sql - functions - arrays - tutorial - programmerblog.net
Php my sql - functions - arrays - tutorial - programmerblog.net
 

More from Ingvar Stepanyan

A very quick intro to astrophotography
A very quick intro to astrophotographyA very quick intro to astrophotography
A very quick intro to astrophotographyIngvar Stepanyan
 
Asyncifying WebAssembly for the modern Web
Asyncifying WebAssembly for the modern WebAsyncifying WebAssembly for the modern Web
Asyncifying WebAssembly for the modern WebIngvar Stepanyan
 
How I tried to compile JavaScript
How I tried to compile JavaScriptHow I tried to compile JavaScript
How I tried to compile JavaScriptIngvar Stepanyan
 
Creating own language made easy
Creating own language made easyCreating own language made easy
Creating own language made easyIngvar Stepanyan
 

More from Ingvar Stepanyan (7)

A very quick intro to astrophotography
A very quick intro to astrophotographyA very quick intro to astrophotography
A very quick intro to astrophotography
 
Asyncifying WebAssembly for the modern Web
Asyncifying WebAssembly for the modern WebAsyncifying WebAssembly for the modern Web
Asyncifying WebAssembly for the modern Web
 
How I tried to compile JavaScript
How I tried to compile JavaScriptHow I tried to compile JavaScript
How I tried to compile JavaScript
 
es6.concurrency()
es6.concurrency()es6.concurrency()
es6.concurrency()
 
React for WinRT apps
React for WinRT appsReact for WinRT apps
React for WinRT apps
 
Creating own language made easy
Creating own language made easyCreating own language made easy
Creating own language made easy
 
JS: Audio Data Processing
JS: Audio Data ProcessingJS: Audio Data Processing
JS: Audio Data Processing
 

Recently uploaded

FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...
FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...
FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...FIDO Alliance
 
Speed Wins: From Kafka to APIs in Minutes
Speed Wins: From Kafka to APIs in MinutesSpeed Wins: From Kafka to APIs in Minutes
Speed Wins: From Kafka to APIs in Minutesconfluent
 
Introduction to Open Source RAG and RAG Evaluation
Introduction to Open Source RAG and RAG EvaluationIntroduction to Open Source RAG and RAG Evaluation
Introduction to Open Source RAG and RAG EvaluationZilliz
 
Linux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdf
Linux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdfLinux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdf
Linux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdfFIDO Alliance
 
Structuring Teams and Portfolios for Success
Structuring Teams and Portfolios for SuccessStructuring Teams and Portfolios for Success
Structuring Teams and Portfolios for SuccessUXDXConf
 
Salesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
Salesforce Adoption – Metrics, Methods, and Motivation, Antone KomSalesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
Salesforce Adoption – Metrics, Methods, and Motivation, Antone KomCzechDreamin
 
A Business-Centric Approach to Design System Strategy
A Business-Centric Approach to Design System StrategyA Business-Centric Approach to Design System Strategy
A Business-Centric Approach to Design System StrategyUXDXConf
 
Behind the Scenes From the Manager's Chair: Decoding the Secrets of Successfu...
Behind the Scenes From the Manager's Chair: Decoding the Secrets of Successfu...Behind the Scenes From the Manager's Chair: Decoding the Secrets of Successfu...
Behind the Scenes From the Manager's Chair: Decoding the Secrets of Successfu...CzechDreamin
 
Enterprise Knowledge Graphs - Data Summit 2024
Enterprise Knowledge Graphs - Data Summit 2024Enterprise Knowledge Graphs - Data Summit 2024
Enterprise Knowledge Graphs - Data Summit 2024Enterprise Knowledge
 
PLAI - Acceleration Program for Generative A.I. Startups
PLAI - Acceleration Program for Generative A.I. StartupsPLAI - Acceleration Program for Generative A.I. Startups
PLAI - Acceleration Program for Generative A.I. StartupsStefano
 
Where to Learn More About FDO _ Richard at FIDO Alliance.pdf
Where to Learn More About FDO _ Richard at FIDO Alliance.pdfWhere to Learn More About FDO _ Richard at FIDO Alliance.pdf
Where to Learn More About FDO _ Richard at FIDO Alliance.pdfFIDO Alliance
 
Demystifying gRPC in .Net by John Staveley
Demystifying gRPC in .Net by John StaveleyDemystifying gRPC in .Net by John Staveley
Demystifying gRPC in .Net by John StaveleyJohn Staveley
 
UiPath Test Automation using UiPath Test Suite series, part 1
UiPath Test Automation using UiPath Test Suite series, part 1UiPath Test Automation using UiPath Test Suite series, part 1
UiPath Test Automation using UiPath Test Suite series, part 1DianaGray10
 
Unpacking Value Delivery - Agile Oxford Meetup - May 2024.pptx
Unpacking Value Delivery - Agile Oxford Meetup - May 2024.pptxUnpacking Value Delivery - Agile Oxford Meetup - May 2024.pptx
Unpacking Value Delivery - Agile Oxford Meetup - May 2024.pptxDavid Michel
 
IESVE for Early Stage Design and Planning
IESVE for Early Stage Design and PlanningIESVE for Early Stage Design and Planning
IESVE for Early Stage Design and PlanningIES VE
 
Choosing the Right FDO Deployment Model for Your Application _ Geoffrey at In...
Choosing the Right FDO Deployment Model for Your Application _ Geoffrey at In...Choosing the Right FDO Deployment Model for Your Application _ Geoffrey at In...
Choosing the Right FDO Deployment Model for Your Application _ Geoffrey at In...FIDO Alliance
 
Strategic AI Integration in Engineering Teams
Strategic AI Integration in Engineering TeamsStrategic AI Integration in Engineering Teams
Strategic AI Integration in Engineering TeamsUXDXConf
 
Custom Approval Process: A New Perspective, Pavel Hrbacek & Anindya Halder
Custom Approval Process: A New Perspective, Pavel Hrbacek & Anindya HalderCustom Approval Process: A New Perspective, Pavel Hrbacek & Anindya Halder
Custom Approval Process: A New Perspective, Pavel Hrbacek & Anindya HalderCzechDreamin
 
AI presentation and introduction - Retrieval Augmented Generation RAG 101
AI presentation and introduction - Retrieval Augmented Generation RAG 101AI presentation and introduction - Retrieval Augmented Generation RAG 101
AI presentation and introduction - Retrieval Augmented Generation RAG 101vincent683379
 
ECS 2024 Teams Premium - Pretty Secure
ECS 2024   Teams Premium - Pretty SecureECS 2024   Teams Premium - Pretty Secure
ECS 2024 Teams Premium - Pretty SecureFemke de Vroome
 

Recently uploaded (20)

FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...
FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...
FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...
 
Speed Wins: From Kafka to APIs in Minutes
Speed Wins: From Kafka to APIs in MinutesSpeed Wins: From Kafka to APIs in Minutes
Speed Wins: From Kafka to APIs in Minutes
 
Introduction to Open Source RAG and RAG Evaluation
Introduction to Open Source RAG and RAG EvaluationIntroduction to Open Source RAG and RAG Evaluation
Introduction to Open Source RAG and RAG Evaluation
 
Linux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdf
Linux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdfLinux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdf
Linux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdf
 
Structuring Teams and Portfolios for Success
Structuring Teams and Portfolios for SuccessStructuring Teams and Portfolios for Success
Structuring Teams and Portfolios for Success
 
Salesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
Salesforce Adoption – Metrics, Methods, and Motivation, Antone KomSalesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
Salesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
 
A Business-Centric Approach to Design System Strategy
A Business-Centric Approach to Design System StrategyA Business-Centric Approach to Design System Strategy
A Business-Centric Approach to Design System Strategy
 
Behind the Scenes From the Manager's Chair: Decoding the Secrets of Successfu...
Behind the Scenes From the Manager's Chair: Decoding the Secrets of Successfu...Behind the Scenes From the Manager's Chair: Decoding the Secrets of Successfu...
Behind the Scenes From the Manager's Chair: Decoding the Secrets of Successfu...
 
Enterprise Knowledge Graphs - Data Summit 2024
Enterprise Knowledge Graphs - Data Summit 2024Enterprise Knowledge Graphs - Data Summit 2024
Enterprise Knowledge Graphs - Data Summit 2024
 
PLAI - Acceleration Program for Generative A.I. Startups
PLAI - Acceleration Program for Generative A.I. StartupsPLAI - Acceleration Program for Generative A.I. Startups
PLAI - Acceleration Program for Generative A.I. Startups
 
Where to Learn More About FDO _ Richard at FIDO Alliance.pdf
Where to Learn More About FDO _ Richard at FIDO Alliance.pdfWhere to Learn More About FDO _ Richard at FIDO Alliance.pdf
Where to Learn More About FDO _ Richard at FIDO Alliance.pdf
 
Demystifying gRPC in .Net by John Staveley
Demystifying gRPC in .Net by John StaveleyDemystifying gRPC in .Net by John Staveley
Demystifying gRPC in .Net by John Staveley
 
UiPath Test Automation using UiPath Test Suite series, part 1
UiPath Test Automation using UiPath Test Suite series, part 1UiPath Test Automation using UiPath Test Suite series, part 1
UiPath Test Automation using UiPath Test Suite series, part 1
 
Unpacking Value Delivery - Agile Oxford Meetup - May 2024.pptx
Unpacking Value Delivery - Agile Oxford Meetup - May 2024.pptxUnpacking Value Delivery - Agile Oxford Meetup - May 2024.pptx
Unpacking Value Delivery - Agile Oxford Meetup - May 2024.pptx
 
IESVE for Early Stage Design and Planning
IESVE for Early Stage Design and PlanningIESVE for Early Stage Design and Planning
IESVE for Early Stage Design and Planning
 
Choosing the Right FDO Deployment Model for Your Application _ Geoffrey at In...
Choosing the Right FDO Deployment Model for Your Application _ Geoffrey at In...Choosing the Right FDO Deployment Model for Your Application _ Geoffrey at In...
Choosing the Right FDO Deployment Model for Your Application _ Geoffrey at In...
 
Strategic AI Integration in Engineering Teams
Strategic AI Integration in Engineering TeamsStrategic AI Integration in Engineering Teams
Strategic AI Integration in Engineering Teams
 
Custom Approval Process: A New Perspective, Pavel Hrbacek & Anindya Halder
Custom Approval Process: A New Perspective, Pavel Hrbacek & Anindya HalderCustom Approval Process: A New Perspective, Pavel Hrbacek & Anindya Halder
Custom Approval Process: A New Perspective, Pavel Hrbacek & Anindya Halder
 
AI presentation and introduction - Retrieval Augmented Generation RAG 101
AI presentation and introduction - Retrieval Augmented Generation RAG 101AI presentation and introduction - Retrieval Augmented Generation RAG 101
AI presentation and introduction - Retrieval Augmented Generation RAG 101
 
ECS 2024 Teams Premium - Pretty Secure
ECS 2024   Teams Premium - Pretty SecureECS 2024   Teams Premium - Pretty Secure
ECS 2024 Teams Premium - Pretty Secure
 

Rust ⇋ JavaScript