$ target/debug/deno tests/002_hello.ts
src/main.rs
- load env args, and set flags
- new isolate
- tokio init (async)
- isolate execute denoMain(); in js/main.js
- isolate execute_mod tests/002_hello.ts
- isolate event loop
- libdeno::deno_execute (See libdeno/api.cc)
- code fetch and maybe compile tests/002_hello.ts
- code_fetch
- compile_sync
- spawn worker compilerMain() in js/compiler.ts 1. compiler.compile
mod_load_deps
for loading dependencies in the loaded ts module
let len = libdeno::deno_mod_imports_len
: the number of dependeicies- for in 0..len
libdeno::deno_mod_imports_get
- resolve module
- code_fetch_and_maybe_compile
mod_load_deps
for recursively loading depedenecy tree.
- while !is_idle: !(ntasks == 0 && deadline)
- complete_op
- done
- ntasks_decrement()
- respond
- libdeno::deno_respond
- compiler.compile
- resolve module
_service: ts.LanguageService
getEmitOutput tests/002_hello.ts