https://github.com/anxolerd/lexyn
https://github.com/anxolerd/lexyn
haskell stack syntax-checking
Last synced: 4 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/anxolerd/lexyn
- Owner: anxolerd
- License: bsd-3-clause
- Created: 2017-09-17T16:08:48.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2017-12-25T22:06:31.000Z (about 8 years ago)
- Last Synced: 2025-07-14T17:42:39.700Z (7 months ago)
- Topics: haskell, stack, syntax-checking
- Language: Haskell
- Size: 11.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.rst
- License: LICENSE
Awesome Lists containing this project
README
=====
Lexyn
=====
.. image:: https://travis-ci.org/anxolerd/Lexyn.svg?branch=master
:target: https://travis-ci.org/anxolerd/Lexyn
Description
===========
**Lexyn** is a simple expression analyzer which checks mathematical expression
for validity. This is also a part of my `High-Performant systems software.
Compilers course`_ assignment.
Currently the **Lexyn** functionality is very limited. Everything Lexyn can is
to tokenize the input string and perform a basic syntax analysis. In future it
will be able to build a parallel execution plans for given expression and
determine the best of them.
Usage
=====
.. code-block:: bash
$ Lexyn '2 + 2'
$ Lexyn '2++2'
Unexpected token `+` at position 3
2++2
^
$ Lexyn '2@@2'
Unexpected symbol '@' at position 2
2@@2
^
Unexpected symbol '@' at position 3
2@@2
^
$ Lexyn '22 +'
Unexpected end of input at position 4
22 +
^
$ Lexyn '2*22 + () - 1'
Empty parens are not allowed at position 9
2*22 + () - 1
^
Building
========
`Haskell stack`_ is used for project development. To build the project just
execute ``stack build`` in the project directory.
.. _`High-Performant systems software. Compilers course`: https://kpi-fict-ip32.github.io/Blog/s09/compilers.html
.. _`Haskell stack`: https://www.haskellstack.org/