Skip to content

hkiaipc/Regex-1

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Regex

A parody of http://code.google.com/p/re1/ with the intention to provide a simple, concise and constructive regex engine implementation.

The parser part is a proof-of-concept design employing Shunting-yard algorithm to illustrate to feasibility to process unary operators and surrounds like parentheses.

Syntax

a?    match 1 or 0 times
a*    match 0 or more times
a+    match 1 or more times
a??   match 1 or 0 times, not greedily
a*?   match 0 or more, not greedily
a+?   match 1 or more, not greedily
.     match any character
|     alternative
(a)   capturing parentheses

Build

make

Usage

./main '(ray|yar)' 'hello, ray'

About

A little regex engine

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C 99.1%
  • Makefile 0.9%