-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Story Statement
As a coder, I can give monogram a pre-defined set of tokenisation rules so that I can restrict the grammar that monogram accepts so it fails early and I can skip the : and ! markers.
Goals
Monogram takes an additional parameter which specifies a tokenisation-rules file e.g. myrules.mg-rules. The rules specify:
-
Identifiers
- Which identifiers may play the role of surround-forms.
- Which identifiers may play the role of prefix-forms.
- Which identifiers may play the role of labels.
-
Operators
- Which operators may play the role of infix-operators
- Which operators may play the role of prefix-operators
-
Delimiters
- Which symbols may play the role of delimiters (brackets)
- Which symbols may play the role of prefix function-call
-
Strings
- Which string quotes are allowed
- Are string tags allowed?
-
Dot
- Is dot notation allowed?
-
Markers
- Is a
!prefix marker allowed? - Is a
:label marker allowed? - Is a standalone
:allowed?
- Is a
-
XML tags
- Are XML tags allowed?
Acceptance Criteria
- Once a token is classified as definitely a prefix form or a label the associated marker syntax is redundant. Reflecting that it may be omitted. If the rules forbid the markers then
:and!will be interpreted as ordinary operators.
Metadata
Metadata
Assignees
Labels
No labels
Type
Projects
Status
Todo