diff --git a/.github/CODE_EXAMPLE.md b/.github/CODE_EXAMPLE.md deleted file mode 100644 index e83165d1..00000000 --- a/.github/CODE_EXAMPLE.md +++ /dev/null @@ -1,194 +0,0 @@ -# Wave Programming Language - Code Examples and Explanation - -This document provides a series of code examples written in the Wave programming language. Each example demonstrates a specific feature or concept in the language, accompanied by a detailed explanation. - -## Input/Output -``` -fun main() { - print("Hello World?\n"); - println("Hello World!"); -} -``` -### Explanation: -* `fun main()`: This defines the main function, which serves as the entry point for the program. -In Wave, the `main` function is where the execution of the program begins, just like in C or Rust. - -* `print("Hello World?\n");`: The `print` function outputs the string `"Hello World?"` without appending a newline character at the end. -The `\n` ensures the output is followed by a newline. - -* `println("Hello World!");`: The `println` function is used to print the string `"Hello World!"` to the console, followed by a newline character. - -* Output: -``` -Hello World? -Hello World! -``` - -This example demonstrates how to use `print` for output without a newline and `println` for output with a newline. - -## Variables and Conditionals -``` -fun main() { - var x: i32 = 5; - var y: i32 = 10; - - if (x < y) { - println("x is less than y"); - } else { - println("x is greater than or equal to y"); - } -} -``` -### Explanation: -* `var x: i32 = 5;` and `var y: i32 = 10;`: These lines declare two variables, `x` and `y`, of type `i32` (32-bit integer), -and assign them initial values of 5 and 10, respectively. - -* `if (x < y) { ... } else { ... }`: This is and `if-else` conditional statement. -It checks if the value of `x` is less than `y`. If the condition is true, it prints `x is less than y`. -Otherwise, it prints `x is greater than or equal to y`. - -* Output: -``` -x is less than y -``` - -This example demonstrates how to declare variables, compare them, and use conditional logic. - -## Loops -### `while` Loop -``` -fun main() { - var i: i32 = 0; - - while (i < 5) { - println(i); - i = i + 1; - } -} -``` - -#### Explanation: -* `var i: i32 = 0;`: This line initializes a variable `i` with the value 0. - -* `while (i < 5) { ... }`: The `while` loop continues executing the code block as long as the condition `i < 5` holds true. -Inside the loop, the current value of `i` is printed, and `i` is incremented by 1. - -* Output: -``` -0 -1 -2 -3 -4 -``` - -### `for` Loop -``` -fun main() { - for (i in 0..4) { - println(i); - } -} -``` - -#### Explanation: -* `for (i in 0..4) { ... }`: The `for` loop iterates over the range `0..4`, effectively printing the values of `i` from 0 to 4. - -* Output: -``` -0 -1 -2 -3 -4 -``` - -This example demonstrates how the same task can be accomplished using a `for` loop, iterating through a specified range instead of manually managing the loop condition. - -## Functions -``` -fun greet(name: str) { - println("Hello, {} !", name); -} - -fun main() { - greet("Wave"); -} -``` - -### Explanation: -* `fun greet(name: str)`: This defines a function called `greet` that takes a single parameter `name` of type `str` (String). - -* `"println("Hello, {} !"), name"`: inside the function, we use a formatted string to print a greeting message that includes the value of `name`. - -* `greet("Wave")`: In the `main` function, we call the `greet` function with the argument `"Wave"`, which outputs the greeting message. - -* Output: -``` -Hello, Wave ! -``` - -This example demonstrate how to define and call a function with parameters in Wave, along with string formatting. - -## Error Handling -``` -fun divide(a: i32, b: i32) -> i32 { - if (b == 0) { - println("Error: Divison by zero"); - return -1; - } - return a / b; -} - -fun main() { - var result: i32 = divide(10, 2); - - if result != -1 { - println("Result: {}", result); - } -} -``` - -### Explanation - -* `fun divide(a: i32, b: i32) -> i32`: This defines a function called `divide` that takes two integers as parameters and returns an integer result. -* `if (b == 0) { ... }`: Inside the function, we check if `b` is zero. If it is, we print an error message and return `-1` to indicate an error. Otherwise, the function performs the division and returns the result. -* `var result: i32 = divide(10, 2)`: In the `main` function, we call `divide` with the arguments `10` and `2`, storing the result in the variable `result`. -* `if result != -1 { ... }`: We then check if the result is not equal to `-1` (indicating an error) and, if valid, print the result. - -* Output: -``` -Result: 5 -``` - -This example demonstrates how to handle errors, such as division by zero, and return an error value. - -## Arrays -``` -fun main() { - var arr = [1, 2, 3, 4, 5]; - - for (num in arr) { - println(num); - } -} -``` - -### Explanation: - -* `var arr = [1, 2, 3, 4, 5];`: This creates an array named `arr` containing the integers from 1 to 5. - -* `for (num in arr) { ... }`: The `for` loop iterates over each element in the array `arr`. In each iteration, the current element is stored in the variable `num`. - -* `println(num);`: Inside the loop, the current value of `num` is printed. - -* Output: -``` -1 -2 -3 -4 -5 -``` - -This example demonstrates how to declare an array and iterate through its elements using a `for` loop. \ No newline at end of file diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml index 1f3c9fb8..baa9b913 100644 --- a/.github/FUNDING.yml +++ b/.github/FUNDING.yml @@ -1,2 +1,2 @@ +open_collective: wave-lang github: [wavefnd, LunaStev] -open_collective: wave-lang \ No newline at end of file diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md deleted file mode 100644 index 6f2b1840..00000000 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ /dev/null @@ -1,33 +0,0 @@ ---- -name: Bug report -about: Create rvalue report to help us improve -title: '' -labels: bug -assignees: '' - ---- - -### Bug Title: -(Brief description of the bug) - -### Environment: -- Operating System: (e.g., Windows 10, macOS, Ubuntu 20.04, etc.) -- Wave Version: (e.g., 1.0.0) -- Execution Environment: (e.g., Local, Server, etc.) - -### Steps to Reproduce: -1. (Step 1 to reproduce the bug) -2. (Step 2 to reproduce the bug) -3. ... - -### Expected Result: -(What should have happened if the bug didn’t occur) - -### Actual Result: -(What actually happened when the bug occurred) - -### Screenshot/Logs: -(Attach relevant screenshots or log files related to the bug) - -### Additional Information: -(Any additional information or special circumstances related to the bug) diff --git a/.github/ISSUE_TEMPLATE/bug_report.yml b/.github/ISSUE_TEMPLATE/bug_report.yml new file mode 100644 index 00000000..3fc331a0 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug_report.yml @@ -0,0 +1,57 @@ +name: Bug report +description: Report a reproducible compiler, language, code generation, or toolchain defect. +title: "[Bug]: " +labels: + - bug +body: + - type: checkboxes + attributes: + label: Before submitting + options: + - label: I searched existing issues for the same problem. + required: true + - label: I can reproduce this with a supported Wave compiler build. + required: true + - type: input + attributes: + label: Wave version + description: Paste the complete output of `wavec --version`. + placeholder: wavec ... + validations: + required: true + - type: input + attributes: + label: Host environment + description: Operating system, architecture, and relevant toolchain versions. + placeholder: Fedora Linux, x86_64, LLVM ... + validations: + required: true + - type: input + attributes: + label: Target triple + description: The selected target, or `host default` if no target was passed. + placeholder: riscv64-unknown-linux-gnu + validations: + required: true + - type: textarea + attributes: + label: Reproduction + description: Include the smallest Wave source and the exact command needed to reproduce the problem. + render: shell + validations: + required: true + - type: textarea + attributes: + label: Expected behavior + validations: + required: true + - type: textarea + attributes: + label: Actual behavior and diagnostics + description: Include complete stdout, stderr, exit status, and backtrace when available. + validations: + required: true + - type: textarea + attributes: + label: Additional context + description: Add related files, regressions, linker/sysroot details, or anything else that may help. diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml new file mode 100644 index 00000000..825cec39 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -0,0 +1,8 @@ +blank_issues_enabled: false +contact_links: + - name: Design discussions and questions + url: https://github.com/wavefnd/Wave/discussions + about: Discuss language design, usage questions, and ideas before opening an implementation issue. + - name: Wave community + url: https://wave-lang.dev/community + about: Get help and talk with other Wave users and contributors. diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md deleted file mode 100644 index de31c2e1..00000000 --- a/.github/ISSUE_TEMPLATE/feature_request.md +++ /dev/null @@ -1,25 +0,0 @@ ---- -name: Feature request -about: Suggest an idea for this project -title: '' -labels: enhancement -assignees: '' - ---- - -### Feature Title: -(Brief description of the feature) - -### Background: -(Explain the reason or background for requesting this feature) - -### Expected Behavior: -(Describe in detail how this feature should behave) - -### User Scenarios: -1. (User scenario 1) -2. (User scenario 2) -3. ... - -### Additional Information: -(Any additional information or considerations related to the feature request) diff --git a/.github/ISSUE_TEMPLATE/feature_request.yml b/.github/ISSUE_TEMPLATE/feature_request.yml new file mode 100644 index 00000000..bf8855d3 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/feature_request.yml @@ -0,0 +1,46 @@ +name: Feature request +description: Propose a focused language, compiler, target, standard library, or tooling improvement. +title: "[Proposal]: " +labels: + - enhancement +body: + - type: checkboxes + attributes: + label: Before submitting + options: + - label: I searched existing issues and discussions for this proposal. + required: true + - type: dropdown + attributes: + label: Area + options: + - Language and semantics + - Parser and frontend + - LLVM code generation + - Target and ABI support + - CLI and diagnostics + - Standard library + - Testing and CI + - Documentation + - Other + validations: + required: true + - type: textarea + attributes: + label: Problem + description: Describe the concrete limitation or use case this proposal addresses. + validations: + required: true + - type: textarea + attributes: + label: Proposed contract + description: Explain the expected syntax, semantics, CLI behavior, or target contract with examples where useful. + validations: + required: true + - type: textarea + attributes: + label: Alternatives and compatibility + description: Describe alternatives considered and any compatibility, migration, ABI, or platform impact. + - type: textarea + attributes: + label: Additional context diff --git a/.github/ISSUE_TEMPLATE/performance-issue-report.md b/.github/ISSUE_TEMPLATE/performance-issue-report.md deleted file mode 100644 index 5372b7e5..00000000 --- a/.github/ISSUE_TEMPLATE/performance-issue-report.md +++ /dev/null @@ -1,33 +0,0 @@ ---- -name: Performance Issue Report -about: Performance Issue -title: '' -labels: question -assignees: '' - ---- - -### Performance Issue Title: -(Brief description of the performance issue) - -### Environment: -- Operating System: (e.g., Windows 10, macOS, etc.) -- Wave Version: (e.g., 1.0.0) -- Hardware: (e.g., CPU, RAM, etc.) - -### Performance Problem Description: -(Describe the performance degradation and its impact) - -### Steps to Reproduce: -1. (Step 1 to reproduce the performance issue) -2. (Step 2 to reproduce the performance issue) -3. ... - -### Expected Performance: -(What performance should have been like if it was working normally) - -### Actual Performance: -(Describe the actual performance observed with degradation) - -### Additional Information: -(Any additional information or context related to solving the performance issue) diff --git a/.github/ISSUE_TEMPLATE/performance_report.yml b/.github/ISSUE_TEMPLATE/performance_report.yml new file mode 100644 index 00000000..e7e549a6 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/performance_report.yml @@ -0,0 +1,53 @@ +name: Performance report +description: Report a reproducible compiler-time, memory, code-size, or generated-code regression. +title: "[Performance]: " +labels: + - performance +body: + - type: input + attributes: + label: Wave version + description: Paste the complete output of `wavec --version`. + placeholder: wavec ... + validations: + required: true + - type: input + attributes: + label: Host and hardware + description: Operating system, architecture, CPU, and memory. + validations: + required: true + - type: input + attributes: + label: Target triple and optimization + placeholder: x86_64-unknown-linux-gnu, -O2 + validations: + required: true + - type: dropdown + attributes: + label: Affected metric + options: + - Compiler time + - Compiler memory + - Generated-code runtime + - Generated-code size + - Link time + - Other + validations: + required: true + - type: textarea + attributes: + label: Reproduction and measurement method + description: Include the source or repository, exact commands, number of runs, and measurement tool. + validations: + required: true + - type: textarea + attributes: + label: Baseline and observed result + description: Provide both values, including units and compiler revisions when comparing commits. + validations: + required: true + - type: textarea + attributes: + label: Profiles and additional context + description: Attach profiles, traces, generated IR/assembly, or other evidence when available. diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md new file mode 100644 index 00000000..f900829e --- /dev/null +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -0,0 +1,22 @@ +## Summary + + + +## Motivation + + + +## Target and compatibility impact + + + +## Validation + + + +## Checklist + +- [ ] Commits include a DCO `Signed-off-by` line. +- [ ] Tests cover new behavior or the PR explains why no test is needed. +- [ ] User-facing changes include documentation or diagnostics updates. +- [ ] The change preserves the license boundary between the compiler and `std/`. diff --git a/.github/doom-demo.gif b/.github/doom-demo.gif deleted file mode 100644 index 8b5da655..00000000 Binary files a/.github/doom-demo.gif and /dev/null differ diff --git a/.github/scalability.svg b/.github/scalability.svg deleted file mode 100644 index 7e310118..00000000 --- a/.github/scalability.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/.github/scalability1.svg b/.github/scalability1.svg deleted file mode 100644 index a640386e..00000000 --- a/.github/scalability1.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/README.md b/README.md index abf0697e..45306c1f 100644 --- a/README.md +++ b/README.md @@ -1,148 +1,168 @@
Systems Programming Language
- - --Created by LunaStev -
- --Website · -Docs · -Blog · -Community -
- + +A systems programming language for explicit native software.
+Direct control, predictable code generation, and practical interoperability from hosted applications to freestanding systems.
+ ++ Website · + Documentation · + Releases · + Community · + Sponsor +
+ + Built with ❤️ by the Wave community
© 2025 Wave Programming Language • LunaStev • Compiler: MPL-2.0 • Standard library: Apache-2.0