Skip to content

harishtpj/HCLAN

HCLAN

All Contributors

made-with-java java-version hclan-version

A simple, yet advanced High level Computing Language

About

HCLAN is an Interpreted, Object Oriented language written in Java. It is also dynamically typed and has a very modern syntax inspired from Java and Python. This interpreter is inspired from jLox of Crafting Interpreters.

Requirements

  • Java JDK >= 8 (latest version is more preferable)

Installation

To Install the interpreter, head over to the releases page and download the latest release of HCLAN interpreter. The zip/tarball file will be named as hclan-<latest_version>.

As of now, HCLAN interpreter is available for Windows as a .msi installer. For other platforms, it is available as a .tar.gz file which currently only contains a .jar file. I'm working on porting the language to the other platforms.

Note that the language's .jar file is completely executable and works on all platforms. But a proper interface still need to be developed for other Platforms

For windows users

  1. Install by double-clicking the installer and Copy the installation location to clipboard
  2. The first step depends which version of Windows you're using:
  • If you're using Windows 8 or 10, press the Windows key, then search for and select "System (Control Panel)".
  • If you're using Windows 7, right click the "Computer" icon on the desktop and click "Properties".
  1. Click "Advanced system settings".
  2. Click "Environment Variables".
  3. Under "System Variables", find the PATH variable, select it, and click "Edit". If there is no PATH variable, click "New".
  4. Add the copied directory location to the beginning of the variable value followed by ; (a semicolon). For example, if the value was C:\Windows\System32, change it to C:\Users\Me\HCLAN\bin;C:\Windows\System32.
  5. Click "OK".
  6. Restart your terminal.
  7. Verify that the path is set by opening a new command window and run hclan -v.

For Mac users:

  1. Copy the \bin location of HCLAN installed folder to clipboard
  2. Open the .bash_profile file in your home directory (for example, /Users/your-user-name/.bash_profile) in a text editor.
  3. Add export PATH="<copied-hclan-bin-path>:$PATH" to the last line of the file, where is the copied directory location of HCLAN.
  4. Save the .bash_profile file.
  5. Restart your terminal.
  6. Verify that the path is set by opening a new terminal and run hclan -v.

For Linux users:

  1. Copy the \bin location of HCLAN installed folder to clipboard
  2. Open the .bashrc file in your home directory (for example, /home/your-user-name/.bashrc) in a text editor.
  3. Add export PATH="<copied-hclan-bin-path>:$PATH" to the last line of the file, where is the copied directory location of HCLAN.
  4. Save the .bashrc file.
  5. Restart your terminal.
  6. Verify that the path is set by opening a new terminal and run hclan -v.

Usage

To run your first program, fire up you favourite text editor and copy the following lines to hello.hln file:

# A Simple Hello, World! program

println "Hello, world!";
println "HCLAN is interesting!";

Then open a new terminal in the same directory as the file and run:

$ hclan hello.hln

For windows users: just run the same command.

You'll see the following output on your terminal:

Hello, world!
HCLAN is interesting!

Support

If you've any questions regarding this project, please check our documentation or file an issue.

Contributing

Contributions are welcome, To contribute please refer to details here.

Contributors

Raam Kumar
Raam Kumar

🎨 🐛

License

Copyright © 2023 M.V.Harish Kumar.

This project is BSD-2 licensed.

Project status

This project is still In its baby steps. Many features need to be added. Thus the stability of the syntax is not guaranteed. However, most features is planned to be retained. Contributers can give their contribution to this project to make this project stable.