~ntietz

US/Eastern

https://ntietz.com

Trackers

~ntietz/hurl-lang

Last active 3 months ago

~ntietz/protocols

Last active 7 months ago

~ntietz/isabella-db

Last active 7 months ago

~ntietz/molecule-reader

Last active 9 months ago

~ntietz/config

Last active 10 months ago

#2 Define and document language grammar 3 months ago

Comment by ~ntietz on ~ntietz/hurl-lang

Nicole Tietz-Sokolskaya referenced this ticket in commit 6875b87.

REPORTED RESOLVED IMPLEMENTED

#2 Define and document language grammar 3 months ago

Comment by ~ntietz on ~ntietz/hurl-lang

Token definitions:

  1. Keywords: let, func, hurl, toss, try, catch, as, return, print, true, false.
  2. Identifiers: Sequences of ASCII alphanumeric characters and underscores, beginning with a letter or an underscore.
  3. String Literals: Sequences of characters enclosed in double quotes (" "). Special characters can be escaped with a backslash (), including " to represent a quote within the string, and \ to represent a backslash.
  4. Boolean Values: true, false.
  5. Numerical Values: Both integers and floating-point numbers. Integers are sequences of digits (0-9). Floating-point numbers consist of one or more digits, followed by a decimal point, followed by zero or more digits.
  6. Operators: +, -, *, /, %, ~.
  7. Punctuation: Parentheses (), curly braces {}, semicolons ;.
  8. Comments: Lines beginning with # are treated as comments and are ignored by the lexer.

#2 Define and document language grammar 3 months ago

~ntietz assigned ~ntietz to #2 on ~ntietz/hurl-lang

#2 Define and document language grammar 3 months ago

Comment by ~ntietz on ~ntietz/hurl-lang

Subtasks:

  1. Define Tokens: First, we should clearly define all the language tokens. Tokens are the smallest units of a program, such as keywords, identifiers, constants, operators, and special symbols.
  2. Define Syntax Rules: After defining the tokens, we can establish the syntax rules. Syntax rules define how tokens combine to form statements and expressions.
  3. Define Comment Syntax: As comments are part of the language grammar, we should also define the rules for them.
  4. Document the Grammar: Once we have the language grammar defined, we should document it thoroughly.

#6 Develop comprehensive tests for grammar, lexer, parser, and formatter 3 months ago

Ticket created by ~ntietz on ~ntietz/hurl-lang

Write comprehensive tests for each component of the language's infrastructure to ensure their correct functionality. This includes tests for the language grammar, the lexer, the parser, and the formatter. For each component, the tests should:

  • Validate the component against various code samples.
  • Ensure edge cases are correctly handled.
  • Confirm proper handling and preservation of comments during the formatting process.

#5 Implement formatter for code beautification 3 months ago

Ticket created by ~ntietz on ~ntietz/hurl-lang

Create a formatter that traverses the AST to generate formatted code. The formatter should apply rules for code indentation, line breaks, space between operators, and other formatting details, including handling of comments. Key components to focus on include:

  • Code traversal from AST.
  • Application of formatting rules as defined.
  • Proper handling and formatting of comments.

#4 Implement parser for syntax validation and AST creation 3 months ago

Ticket created by ~ntietz on ~ntietz/hurl-lang

Develop a parser that checks whether the sequence of tokens from the lexer conforms to the syntax rules defined in the language grammar. The parser should also construct an Abstract Syntax Tree (AST) from the tokens. Key features to implement include:

  • Syntax validation according to language grammar.
  • AST construction from valid tokens, including nodes for comments.

#3 Develop lexer for token identification 3 months ago

Ticket created by ~ntietz on ~ntietz/hurl-lang

Implement a lexer that will break the input code into a sequence of tokens, including comments. The lexer should correctly identify all tokens as defined in the language grammar, including:

  • All keywords.
  • All constants.
  • Variables and function names.
  • All operators.
  • Parentheses, curly braces, semicolons, and comments.

#2 Define and document language grammar 3 months ago

Ticket created by ~ntietz on ~ntietz/hurl-lang

Develop a detailed specification of the language grammar. This includes identifying and defining all language tokens and writing syntax rules for all language constructs. Key aspects to consider include:

  • Keywords: let, func, hurl, toss, try, catch, as, return, print.
  • Constants: string literals, boolean values, numerical values.
  • Variables and function names (identifier rules).
  • Operators: +.
  • Other tokens: parentheses (), curly braces {}, semicolons ;, and comments.
  • Syntax rules for function definitions, control flow with try-catch blocks, exception throwing using hurl and toss, and printing with print.

#1 Add license 3 months ago

Ticket created by ~ntietz on ~ntietz/hurl-lang

Currently, no one can use Hurl for any real-world tasks, as there is not a license. This is problematic and will limit the language's reach and growth. To ensure that everyone can put this into production at their workplaces, let's add a license.

We need to decide which license to use. Suggestions are welcome.