Draft:Hare (programming language)
Submission declined on 19 July 2024 by KylieTastic (talk).
Where to get help
How to improve a draft
You can also browse Wikipedia:Featured articles and Wikipedia:Good articles to find examples of Wikipedia's best writing on topics similar to your proposed article. Improving your odds of a speedy review To improve your odds of a faster review, tag your draft with relevant WikiProject tags using the button below. This will let reviewers know a new draft has been submitted in their area of interest. For instance, if you wrote about a female astronomer, you would want to add the Biography, Astronomy, and Women scientists tags. Editor resources
| ![]() |
Submission declined on 7 July 2024 by SafariScribe (talk). This submission is not adequately supported by reliable sources. Reliable sources are required so that information can be verified. If you need help with referencing, please see Referencing for beginners and Citing sources. This draft's references do not show that the subject qualifies for a Wikipedia article. In summary, the draft needs multiple published sources that are: Declined by SafariScribe 42 days ago.
| ![]() |
![]() | |
Designed by | Drew DeVault |
---|---|
Stable release | 0.24.2
/ 2024-7-14 |
Typing discipline | Static, strong, inferred, structural |
Memory management | Manual |
Platform | x86-64, ARM64, riscv64 |
OS | Cross-platform: Linux, FreeBSD, NetBSD. OpenBSD (Unofficially: MacOS) |
Filename extensions | .ha |
Website | harelang |
Influenced by | |
C, C++, Go, Rust, Zig |
Hare is an imperative, statically typed system programming language created by Drew DeVault.[1]
The language began development in December 2019 and was initially released on April 25, 2022.[2] Hare aims to be a lightweight, type safe, and intuitive alternative to C.[3]
Goals
[edit]The goals of Hare's design are:
- To create a "conservative" successor to C, offering polish with minimal bloat.[2]
- The ability for any single programmer to fully understand the Hare toolchain.[4]
Not a C replacement
[edit]According to its creator, Hare does not intend to replace C in all its areas of application:
"Hare is not a “kitchen sink” language: Hare does not attempt to solve every problem, but it does strive to solve the problems we’re interested in well."
[...]
"Hare aims to be successful within its niche for the programmers that find its ideas compelling, and nothing further. [...] I was pretty frustrated to see the “Hare is a C replacement” mantra repeated in the media despite issuing no such claims."
– Drew DeVault, on the goals of the Hare programming language[4]
Hare gears itself towards an audience which shares its creators' philosophy of hygienic programming.
Description
[edit]Hare is intended to offer an alternative workflow for C programmers. It is designed for low-level systems programming, marketing itself as simple, stable and robust.[5][6] The language features a static, inferred type system as well as manual memory management.[4][7] Hare's innovations upon C include full UTF-8 support, a tagged union based error handling system[8] and a context-free interpreter.[7] The language emphasises broad applicability and portability.[9]
Hare runs on Linux, as well as all BSD operating systems.[10]
A lightweight language
[edit]The Hare compiler is lightweight, with the language as a whole geared towards portability, requiring only 1.4MB of storage.[5] Hare utilises the QBE compiler tool, unlike many modern programming languages which utilise LLVM.[4][11] It also aims to minimise reliance on external dependencies.[1][6]
Drawbacks
[edit]The language lacks many features present in other C alternatives the likes of Zig or Rust, such as code evaluation at compile-time.[citation needed] Hare also does not, nor does it plan to in the future, natively support functionality on proprietary operating systems such as MacOS and Microsoft Windows, though there exist third-party dependencies that provide such support.[4]
The most widely criticised aspect of Hare is its complete lack of generics, requiring developers to implement their own basic data structures, such as the hash table.[12]
Examples
[edit]Multilingual HelloWorld
[edit]This example demonstrates the high-level nature of Hare's syntax and its inferred type system.
use fmt;
export fn main() void = {
const greetings = [
"Hello, world!",
"¡Hola Mundo!",
"Γειά σου Κόσμε!",
"Привіт, світе!",
"こんにちは世界!",
];
for (let greeting .. greetings) {
fmt::println(greeting)!;
};
};
→ The official Hare website offers a short tutorial course.
See also
[edit]References
[edit]- ^ a b Kaur, Japsimran. "Hare programming language - A new addition to computer languages". Tech Gig. Retrieved 2024-07-18.
- ^ a b "Announcing the Hare programming language". harelang.org. Retrieved 2024-07-07.
- ^ "The Hare Programming Language". vladh.net. 2022-04-24. Retrieved 2024-07-18.
- ^ a b c d e "Frequently asked questions". harelang.org. Retrieved 2024-07-07.
- ^ a b "The Hare programming language". harelang.org. Retrieved 2024-07-18.
- ^ a b Claburn, Thomas (2022-04-26). "Heresy: Hare programming language an alternative to C". The Register. Retrieved 2024-07-18.
- ^ a b "Hare's advances compared to C". harelang.org. Retrieved 2024-07-18.
- ^ "Safety features of the Hare programming language". harelang.org. Retrieved 2024-07-19.
- ^ Developer Voices (2023-12-06). Will we be writing Hare in 2099? (with Drew DeVault). Retrieved 2024-07-18 – via YouTube.
- ^ "Installation guide — Hare documentation". harelang.org. Retrieved 2024-07-18.
- ^ "What is LLVM? The power behind Swift, Rust, Clang, and more". InfoWorld. Retrieved 2024-07-18.
- ^ Eini, Oren. "Criticizing Hare language approach for generic data structures". Ayende. Retrieved 2024-07-19.
- in-depth (not just passing mentions about the subject)
- reliable
- secondary
- independent of the subject
Make sure you add references that meet these criteria before resubmitting. Learn about mistakes to avoid when addressing this issue. If no additional references exist, the subject is not suitable for Wikipedia.