►
From YouTube: Node.js N-API Team meeting - 24 Feb 2020
Description
A
B
A
B
B
Eventually,
it
was
like,
as
I
was
putting
in
my
code
to
to
understand
what
was
going
on.
It
started,
working
and,
of
course,
and
when
I,
when
I
removed
all
my
changes,
it's
not
working
on
the
development.
So
it's
it's,
but
it's
failing
in.
If
I
run,
if
I
run
say
up
there
multiple
times,
it's
failing
on
different
builds
in
different
ways.
So,
okay.
C
B
B
A
C
C
B
So
the
first
step
is
to
get
the
get
the
existing
examples
onto
the
foundations
example
site,
and
I'm
working
on
that
I
am.
I've
got
a
PR
in
in
I'm
working
on
a
PR,
so
we
get
those
moved
in.
But
then
the
next
step
is
to
decide
how
we're
going
to
publish
the
text
and
write
I'm.
We
need
I
feel
I
need
some
direction
there
from
from
from
the
team.
B
C
A
D
A
A
B
A
A
B
A
B
C
B
On
many
of
them
we
point
we
point
the
reader
to
the
repo
like
here's,
the
repo,
if
you
want
to
just
play
around
with
it,
so
you
know
the
other
advantage
of
getting
all
of
the
examples
into
the
repo
is
we
could
run
nightly.
Ci
on
them
and
and
we'd
have
a
great
deal
of
confidence
that
the
code
examples
actually
do
continue
to
work
right.
A
A
B
D
Just
have
a
general
question,
then:
how
much
flex
a
bit
would
we
have
with
changes
that
we
would
need
like
if
we
want
to
make
changes?
How
much
flexibility
would
we
have
if
it
were
on
that
the
main
nodejs
org
page?
That's
sort
of
my
main
question,
because
when
that's
on,
when
they're
hosted
on
github
I
feel
like
it's
easy
to
change.
They're
raised.
B
A
A
D
Nice
yeah,
okay,
make
sense.
Maybe
we
can
just
like
prioritize
this
list
and
then,
depending
on
how
much
visibility
it
gets
then
bend
it
go
higher
on
the
no
js'
org
I
feel
like
I.
Think,
since
we
have
so
much
flexibility
on
what
we
have
on,
you
know
the
github
repos.
You
know
if
we
polished
that
off,
we
polished
that
off
then,
maybe,
depending
on
how
much
visibility
that
gets.
B
B
C
A
It
would
only
be
like
if
we
want
to
you
know
if
we
said
hey,
let's
try
and
make
it
more
visible
on
the
website
or
whatever
or
there's
some
other
reason.
Like
you
said
you
know,
we
might
get
more
people
reviewing
helping
with
the
wording
if
we
wanted
that
the
nodejs
one
might
make
sense,
but
the
to
me
it
also
like
would
make
sense
if
there
was
like
a
workshop
subdirectory
in
here,
uh-huh.
A
B
B
A
A
C
B
B
B
C
C
If
you
make
the
tutorial
text
itself
to
readme
MD
and
then
that
will
be
shown
automatically,
and
there
won't
be
that
I
don't
believe,
there
will
be
so
many
files
in
that
directory
that
that
it
would
be
swept
under
all
those
files,
and
so
people
will
be
like
okay
well,
this
is
just
a
bunch
of
files.
Yeah.
B
D
Of
the
examples,
I
think
at
least
the
first
hello
world
is
kind
of
like
that,
where
it
goes
through
the
code
and
then
you
can
actually
just
npm
install
and
you
have
everything.
So
maybe
it
would
be
something
similar
to
that
for
their
tutorials.
And
then
you
if
we
can
make
sure
that
the
the
code
matches
with
a
tutorial
yeah.
D
D
C
A
B
C
B
B
A
B
And
then
on,
this
I
have
a
question
for
Kevin
because
he
contributed
some
code
for
the
workshop
in
Montreal
and
for
thread:
safe
functions,
Kevin
and
you're.
The
example
that
you
contributed
has
the
code
embedded
in
the
markdown
and
so
I
think
would
be
good
to
get
that
into
a
separate
example.
Directory
like
a
working
example.
So
is
that
something
that
you
would
like
to
do,
or
would
you
like
me
to
do
that?
B
B
A
B
D
A
A
B
D
D
So
this
comment
here
so
basically
over
yeah.
This
comment
here.
So
the
issue
that
we
have
is
that
the
current
callback
implementation
that
we
have
ignores
the
context
parameter
that
exists
in
the
third
safe
function.
So
what
we're
trying
to
do
is
figure
out
a
way
how
we
can
add
that
so
one
way
that
I've
been
able
to
do.
That
is,
if
you
click
that
link
in
this
comment.
This
call
that
rocker
wrapper
to
be
a
class
with
your
constructor.
D
So
the
the
previous
callback
definition
is
used
to
be
whatever.
What's
on
that,
first
line
for
a
to
two
to
zero
Ram.
Well,
that
used
to
be
the
previous
definition
and
now
I've
added.
That's
second
definition,
and
basically
this
callback
wrapper
is
now
a
accepts
either
as
a
constructor
and
then
depending
on
which
one
has
been
set.
Calls
either
one
right.
So
this
is
sort
of
like
a
wrapper
for
that,
but
now,
if
so
that's
the
implementation
that
I
went
for
that.
D
D
D
D
A
D
D
It
but
the
reason
I
think
it
was
completely
ignored
here
was
there
was
no
way
to
properly
typecast
it
to
the
context,
because
the
context
is
only
passed
in
the
the
new
function
call
and
its
own.
It's
sort
of
internal
and
I
guess
the
original
author
of
the
the
code
thought
it
was
better
to
maybe
not
past
the
void
context,
because
there
was
no
way
to
promptly
type
pastor
or
something
because
I've
tried
making.
This
also
be
a
templated,
but
I've
had
failed
for
several
hours.
D
C
Yeah
I
guess
yeah,
so
so
we've
we've
added
this
we've
added
this
ability.
This
is
this
is
like
an
add-on
to
to
the
classical
thread
safe
function,
where
you
can
specify
the
callback
per
that
item.
You
know
so
yeah.
That's
that's
what
complicates
matters
because
the
the
core
implementation
just
accepts
one
callback
and
it
always
calls
the
same
function
right.
C
So
so
we've
added
the
level
of
dynamism
here
with
with
with
disability,
to
to
specify
a
callback
at
every
point,
and
in
fact,
in
fact,
if
we
do
it
this
way,
you
know
some
data
items
may
have
callbacks,
which
are
which
have
a
context.
Others
may
have
callbacks,
which
do
not
have
a
context.
You
know
so
so
that
makes
it
sort
of
potentially
unnecessarily
heterogeneous.
D
D
Because
correct,
maybe
that
has
more
because
one
of
the
issues
is
the
the
context
really
is
part
of
the
t
sfm,
but
we
lose
that
type
safety.
When
you
don't
have
it
templated
with
the
third
say
fashion,
exactly
we
would
gain
yeah,
so
we
would
gain.
We
would
gain
type
safety
if
we
were
to
have
a
new
attempt,
a
new
templated
thread-safe
function.
That
has
a
context,
but
I
guess,
since
the
context
is
optional,
maybe
this
thread-safe
function
with
no
context
would
be
this
one.
D
C
Can
we
can
we
declare
a
specialization
of
the
threats,
a
function
with
like
like
a
void
context,
and
then,
if
people
I,
don't
remember
my
my
C++
well
enough
to
know
whether
that
will
allow
them
to
optionally
template
it
or
not
so
like.
If
they
don't
template
it,
they
get
the
void
template
and
if
they
do
they
get
they
well,
then
they
make
their
own
it's
by
a
specialization.
Is
that
possible?
So
you
know
like
well
yeah,
I,
guess:
I,
guess
you
can
do
something
like
template.
C
You
know
type
name,
type
name
context
type
equals
void
right,
so
you
can
specially.
You
can
specify
like
a
default
data
type
for
the
context
in
the
in
the
template,
argument
right
and
then,
if
they
don't
say
anything,
then
they
don't,
then
they
get
the
void
context
and
then
we
can.
We
can
specialize
for
that.
We
can
provide
a
specialization
for
that,
and
so
they
can
have
book.
They
can
have
it
both
ways
right.
C
D
Either
but
I
think
that's
possible
either
either
that
you
would
have
the
existing
thread-safe
function
class
as
is,
and
then
you
can
create
a
template,
'add
thread-safe
function,
class
and
the
template
parameter
has
to
be
provided
and
I.
Think
that
may
be
backwards,
compatible
I
think
either
way.
I
don't
know,
I'd
have
to
check
also
yeah.
C
Yeah
yeah
yeah
yeah
definitely
definitely
have
to
check
yeah
but
I
think
I
think
you're
right
in
that
you
know.
If
it's
not
templated,
then
the
context
should
not
be.
It
should
not
be
possible
to
use
the
context
because
then
we,
you
know
you
know
you
based-
have
to
pass
it
through
as
a
void
star
and
then
leave
it
up
to
the
consumer
to
to
cast
it
properly
and
then
at
that
point
we're
not
really
adding
value
right
over
over
the
core
API.
C
Haven't
really
had
a
chance
to
look
at
it
to
look
at
no
dad
on
API
ones,.
C
Yeah
I'm,
mostly
just
waiting
for
for
the
still,
which
is
waiting
for
the
instance
data
to
to
learn
so
so
we
can.
We
can
do
the
instance
data
stuff,
because
we
I
think
I
stayed
submit
the
instance
that
a
PR
here,
but
it's
kind
of
on
hold
because
it
cannot
land
until
we
have
instance,
data
back
ported
everywhere
and
even
then
it's
it's.
It's
I
think
it's.
It
would
have
to
be
experimental.
That's
it.
C
Okay,
oh
and
I
should
check
on
the
in
core.
I
should
check
on
that
on
that
sec
fault
I
forget
where
I
left
that
whole
thing
where,
where,
where
I
changed
the
way
the
instance
data
is
being
handled
as
being
just
just
another
reference,
because
I
think
that
needs
to
be
back
ported
right,
look
up
anything
here
or
let
me
see,
but
a
little
can
you
see,
I
have
to
see
it's
I
think
it's
one
of
my
close
PRS
I.
Think
I
marked
it
as
like
LTS
watch,
but
but
I'm
not
sure
see.
C
Free
free
instance,
data
is
reference,
okay,
so
so
this
needs
to
be
back
ported
because
you
this
was
so
basically,
if
you
look
at
31
638
in
in
core,
basically
what's
going
on
is
is
if
you,
if
you
have
a
I,
discovered
this
while
doing
the
instance
data
for
for
for
know
that
on
API,
like
the
the
instance
that
observe
sorry
is
that
if
you
were
a
PR,
this
is
a
PR
31
638
in
core
31.
Okay.
So
it's
not
tagged
with
an
epi.
C
A
C
Yeah
yeah
yeah,
so
so
this
this.
This
is
basically
needed,
because
if
you
have
instance
data
and
inside
the
instance
that
you
store
a
reference
right,
which
is
a
very
common
use
case,
you
know
storing
like
a
reference
to
a
constructor
inside
the
instance
data,
and
then
you
and
then,
if
you,
if
you
free
the
instance,
data
as
as
it
was
being
freed
before
then
then.
Basically,
first,
you
are
freeing
all
the
outstanding
references
and
then
you
free
the
instance
data
right.
C
But
if
the
instance
data
has
a
reference
and
that
already
got
freed
when
the
when
the
linked
list
got
destroyed.
So
so
basically,
what
needs
to
happen
is
that
the
the
instance
data
needs
to
be
part
of
that
linked
list
so
that,
if
it
frees
something,
then
then
it
removes
it
from
the
linked
list
and
it
doesn't
get
called
again
so
that
that
was
basically
this
thing,
and
this
is
needed
for
for
doing
instance,
that
I
know
that
on
API,
but
before
we
do
that.
All
of
this
needs
to
get
back
ported.
A
C
No,
no,
no,
no!
No!
No,
not
v10!
Only
v12,
because
in
v10
we
don't
do
the
the
freeing
of
the
references
so
so
that
never
got
back
ported,
okay
to
be
ten,
which
basically
means
that
in
v10,
yes,
you
can
do
thread,
you
could
do
worker
threads
and,
yes,
you
can
do
add-ons
on
worker
threads,
but
but
they
won't
really
get
freed.
So
so
there
will
be
leaks
and
stuff.
Okay,
yeah.
C
Like
hehe,
it
was
actually
his
suggestion
that
got
me
started
on
this
whole
thing
because
he
suggested
like
okay
well,
if
you're
gonna
have
instance
that
or
then
you
might
as
well
during
the
free
process,
you
might
as
well
pass
the
N
VIN
so
that
if
there
are
any
like
an
API
related
objects
stored
on
the
instance
data
that
they
can
be
freed
at
that
point
right.
So
the
Moses
suggestion
and
then
I
realized
that
if
I
had
a
constructor,
then
if
I
freed
that
it
crashes.
So
that
led
me
to
this.
C
D
C
That
I
figured
okay.
Why
don't
we
add
a
method
on
tune,
a
pmf
which
is
you
know
just
retrieve
instance
them.
You
know,
and
it's
not
as
it's
not
as
type
safe,
because
because
you
know
you
cannot
template
the
end
by
Deeley,
we
would
template
the
end.
You
know
you
have
the
instance
data
type,
but
but
in
this
case
you
can
only
template
the
method.
D
A
C
C
It's
just
I
mean
we
have
the
back
port
in
progress,
for
instance
that
are
for
10,
but
it's
just
actually
antenna
will
get
freed
because,
because
it'll
be
a
special
case
right,
but
all
the
references
won't
get
freed,
which
is
fine,
because
then
it
won't
crash,
at
least
right,
because
when
you
delete
it,
when
you
delete
the
nappy
ends,
it'll
call
the
instance.
Data
finalizar,
but
it
won't
call.
The
finalizar
is
on
all
the
outstanding.
The
references
like
it
does
in
12
and
master.