It’s a new language called Wyvern—named after a mythical dragon-like animal that only has two legs instead of four—and it’s supposed to help programmers design applications and websites without having to rely on different stylesheets and amalgamations spread across different files and programming languages.
Goal. The goal of Wyvern is to be an excellent programming language for engineering web and mobile applications. While the area of focus is important, the language is really driven by engineering needs. Engineers understand the need to balance multiple factors: with respect to a language, those factors include developer productivity, assurance of the end product, and run-time efficiency.
Approach. Wyvern begins with a simple core language with good support for object-oriented programming as well as functional abstractions. It builds on this to address the challenges outlined above through a number of strategies:
- Flexible syntax. While most existing web and mobile applications are cobbled together from multiple artifacts written in diverse languages and notations, Wyvern will, like Ruby, have an flexible enough syntax for developers to express all these artifacts within a single programming language, using an internal DSL strategy. Internal DSL will also support declarative security policy expression within the language.
- Strong, extensible typechecking. Like statically typed languages such as Java, Wyvern will have a strong static type system that can aid in ensuring basic safety and security properties of programs, as well as provide the productivity and coordination benefits of types. Unlike the Java base language, but reminiscent of Scala’s compiler plugins or Java’s annotation processors, Wyvern’s static checking system is extensible with additional rules for checking the artifacts defined in internal DSLs within Wyvern.
- Secure-by-default language and library constructs. Wyvern will provide built-in datatypes that are secure by default. The default integer type is a mathematical integer with unlimited range. Programmers can express range-limited integers by providing a limit, which the system then verifies (either statically or dynamically). When declaring a variable of type string, developers specify the string’s expected format. Database access is done through an internal DSL for querying, and queries cannot be insecurely constructed from strings.
- High-level abstractions for architecture and data. Leveraging Wyvern’s support for DSLs, programmers will be able to describe the architecture of an application within the language, have it be enforced by the type system, and have it be implemented by the compiler and runtime. The architecture will permit description of distributed programs, with custom protocols for communication supported through code generation via Wyvern’s extension facilities. Data structures in Wyvern can be described at the level of abstraction of databases, facilitating database integration, querying, and rich semantic constructs such as bidirectional relationships between objects. These abstractions support analysis of security properties that are data- or architecture-dependant.