NovaLang is a modern, compiled programming language that combines the elegance of Python's syntax with the performance of compiled languages. While it shares a similar syntax with Python, NovaLang is not a Python compiler or interpreter - it's a completely independent language designed for high performance and type safety.
Key features:
- Python-like syntax for easy learning and adoption
- Compiled to native code for superior performance
- Strong type system for better reliability
- Modern language features and optimizations
- LLVM-based compilation pipeline
- Ubuntu/Debian Linux
- CMake 3.10 or higher
- LLVM 14
- C++17 compatible compiler
- Build essentials
- Install dependencies:
sudo apt-get install -y build-essential cmake git llvm-14 llvm-14-dev clang-14 libclang-14-dev- Clone the repository:
git clone https://github.com/yourusername/NovaLang.git
cd NovaLang- Build the project:
mkdir build && cd build
cmake ..
makeCreate a file named hello.nova:
def main():
print("Hello, NovaLang!")Compile and run:
./compiler hello.novaNovaLang includes a comprehensive test suite to ensure language features work correctly. The test suite is organized into three main categories:
-
Basic Language Features
- Variable declarations and assignments
- Operators
- Conditional statements
- Loops
- Functions
-
Advanced Language Features
- Variable scopes
- Data structures
- Type inference
- Error handling
- Mathematical operations
-
Object-Oriented Features
- Classes
- Inheritance
- Encapsulation
To run all tests, use the provided script:
./run_tests.shTo run a specific test, use:
./run_test.sh 01_variables # Replace with the test name you want to runTo capture the current output of tests as the expected output, use the provided script:
./capture_expected.shThis will create files in the test/expected/ directory, which will be used for verification in subsequent test runs.
For more detailed information about the test suite, see the test/README.md file.
We welcome contributions from the community! Here's how you can help:
- Fork the repository
- Create a feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add some AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
Please make sure to update tests as appropriate and follow our coding style guidelines.
This project is licensed under the MIT License - see the LICENSE file for details.
- LLVM Project for providing the compiler infrastructure
- Python for inspiring the syntax design
- All contributors who help make NovaLang better