#compiler #vba #vb6

bin+lib trashcan

a simple language which compiles to Visual Basic 6 / VBA

1 unstable release

Uses old Rust 2015

0.1.0 Apr 14, 2019

#649 in Programming languages

GPL-3.0-or-later

360KB
9K SLoC

trashcan

"the name of this trashcan is Visual Basic"

trashcan is a simple language with abbreviated syntax (similar to Rust, in which the compiler is not coincidentally written) which compiles to Visual Basic (the old, gross one).

Key features of the trashcan language over VB include:

  • No more damn case insensitivity
  • Short-circuiting boolean expressions
  • Generic types and functions
  • Simplified iteration (for-each loops)
  • Mandatory typing with limited type-checking enhancements
  • Syntactic conveniences (e.g. += and friends)
  • Array and structure literals
  • Objects with constructors (use validated only for trashcan code)
  • Somehow, improved error handling (?)
  • Closures (?)

trashcan is inspired by previous work on extending the VB language with m4 macros: https://gist.github.com/derrickturk/5c01caab93bbd6bc9ddd

work in progress, licensed for commercial or non-commercial use under GPL 3.0 or later

Critical implementation note:




(c) 2017-2019 dwt | terminus data science, LLC

No runtime deps