Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@jasonsbarr
Copy link
Owner

@jasonsbarr jasonsbarr commented May 30, 2024

  • MemberExpressions as types in type annotations
  • modules and provides (all definitions provided)
  • import and from forms with aliasing
  • determine module location conventions
  • resolve modules from member expression and dependency string
  • building and traversing the dependency graph
  • load modules via an output modules.js file that imports all modules used in a program and constructs them based on dependency order
  • Conventions for modules:
    • first item in import member expression is Wanda - module is in compiler lib/ directory
    • Modules - module is in node_modules/
    • Names for folders/files are PascalCase in code, lisp-case in folder/file names
    • No index files, e.g. like index.js or module.py
    • Main file in a module has the same filename as the folder it's in
    • Last member of import declaration member expression is the file
    • build/ directory preserves local lib file/folder structure
  • export types from a module
  • handle modules in the type checker
  • a library in Wanda that can be imported
  • compile toplevel to main module when outputting file(s)
  • main module can receive process.argv
  • main module returns main function that receives argv as its sole argument
  • CLI compiles all modules to individual files and imports properly when given a toplevel module with imports
  • option to bundle compiled output
  • __module__ variable available in every module with module name
  • standardized project structure
  • CLI can scaffold new project
  • wanda run command can run a whole project, not just a single file
  • use import declaration inside REPL

jasonsbarr added 30 commits May 31, 2024 11:03
…on't be available to 3rd party module creators or modules defined outside the compiler
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants