Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 10 additions & 2 deletions syntaxes/syntax-test.sudo
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,13 @@ A quick cheat sheet for SudoLang syntax.

## Interfaces

type DateTime = Number(POSIX time, e.g. JS Date.now())

Meta {
id: String(cuid2)
createdAt: DateTime
}

DisplayTheme {
mode: "light" | "dark"
name: String
Expand All @@ -20,7 +27,8 @@ UserPreferences {
}

User {
id: String
// spread can be used for interface composition
...meta

Copilot AI Jan 15, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The spread operator references ...meta (lowercase), but the interface is defined as Meta (uppercase) on line 13. For consistency, this should be ...Meta to match the interface name, or the interface should be renamed to meta if following a lowercase convention for type instances.

Suggested change
...meta
...Meta

Copilot uses AI. Check for mistakes.
displayName
preferences
}
Expand Down Expand Up @@ -189,7 +197,7 @@ processedData = rawData |> normalize |> filter |> sort

## Disallowed Keywords

Should generate a warning for disallowed keywords.
Should generate a warning for disallowed keywords, e.g. `class`, `extends`, and `super`. Favor composition over inheritance.

class Foo extends Bar {
constructor() {
Expand Down