diff options
author | Dominic Chen <d.c.ddcc@gmail.com> | 2013-07-25 10:58:00 +0100 |
---|---|---|
committer | Dominic Chen <d.c.ddcc@gmail.com> | 2013-07-25 10:58:00 +0100 |
commit | 032a2dedd1d3d033bcc410c3de07e6ed0f701ac0 (patch) | |
tree | da6a64772f9440601c7b0efd816b06c40bdf90d8 /www/resources | |
parent | 4df4cee1ef65b197020871095cc16d377c9a1996 (diff) | |
download | klee-032a2dedd1d3d033bcc410c3de07e6ed0f701ac0.tar.gz |
remove www from master branch
Diffstat (limited to 'www/resources')
-rw-r--r-- | www/resources/Regexp.c.html | 78 | ||||
-rw-r--r-- | www/resources/get_sign.c.html | 37 | ||||
-rw-r--r-- | www/resources/islower.c.html | 33 |
3 files changed, 0 insertions, 148 deletions
diff --git a/www/resources/Regexp.c.html b/www/resources/Regexp.c.html deleted file mode 100644 index cb3e3d75..00000000 --- a/www/resources/Regexp.c.html +++ /dev/null @@ -1,78 +0,0 @@ -<!DOCTYPE html PUBLIC "-//IETF//DTD HTML 2.0//EN"> -<HTML> -<HEAD> -<TITLE>Enscript Output</TITLE> -</HEAD> -<BODY BGCOLOR="#FFFFFF" TEXT="#000000" LINK="#1F00FF" ALINK="#FF0000" VLINK="#9900DD"> -<A NAME="top"> -<A NAME="file1"> -<H1>Regexp.c</H1> - -<PRE> -<I><FONT COLOR="#B22222">/* - * Simple regular expression matching. - * - * From: - * The Practice of Programming - * Brian W. Kernighan, Rob Pike - * - */</FONT></I> - -#<B><FONT COLOR="#5F9EA0">include</FONT></B> <B><FONT COLOR="#BC8F8F"><klee/klee.h></FONT></B> - -<B><FONT COLOR="#228B22">static</FONT></B> <B><FONT COLOR="#228B22">int</FONT></B> <B><FONT COLOR="#0000FF">matchhere</FONT></B>(<B><FONT COLOR="#228B22">char</FONT></B>*,<B><FONT COLOR="#228B22">char</FONT></B>*); - -<B><FONT COLOR="#228B22">static</FONT></B> <B><FONT COLOR="#228B22">int</FONT></B> <B><FONT COLOR="#0000FF">matchstar</FONT></B>(<B><FONT COLOR="#228B22">int</FONT></B> c, <B><FONT COLOR="#228B22">char</FONT></B> *re, <B><FONT COLOR="#228B22">char</FONT></B> *text) { - <B><FONT COLOR="#A020F0">do</FONT></B> { - <B><FONT COLOR="#A020F0">if</FONT></B> (matchhere(re, text)) - <B><FONT COLOR="#A020F0">return</FONT></B> 1; - } <B><FONT COLOR="#A020F0">while</FONT></B> (*text != <B><FONT COLOR="#BC8F8F">'\0'</FONT></B> && (*text++ == c || c== <B><FONT COLOR="#BC8F8F">'.'</FONT></B>)); - <B><FONT COLOR="#A020F0">return</FONT></B> 0; -} - -<B><FONT COLOR="#228B22">static</FONT></B> <B><FONT COLOR="#228B22">int</FONT></B> <B><FONT COLOR="#0000FF">matchhere</FONT></B>(<B><FONT COLOR="#228B22">char</FONT></B> *re, <B><FONT COLOR="#228B22">char</FONT></B> *text) { - <B><FONT COLOR="#A020F0">if</FONT></B> (re[0] == <B><FONT COLOR="#BC8F8F">'\0'</FONT></B>) - <B><FONT COLOR="#A020F0">return</FONT></B> 0; - <B><FONT COLOR="#A020F0">if</FONT></B> (re[1] == <B><FONT COLOR="#BC8F8F">'*'</FONT></B>) - <B><FONT COLOR="#A020F0">return</FONT></B> matchstar(re[0], re+2, text); - <B><FONT COLOR="#A020F0">if</FONT></B> (re[0] == <B><FONT COLOR="#BC8F8F">'$'</FONT></B> && re[1]==<B><FONT COLOR="#BC8F8F">'\0'</FONT></B>) - <B><FONT COLOR="#A020F0">return</FONT></B> *text == <B><FONT COLOR="#BC8F8F">'\0'</FONT></B>; - <B><FONT COLOR="#A020F0">if</FONT></B> (*text!=<B><FONT COLOR="#BC8F8F">'\0'</FONT></B> && (re[0]==<B><FONT COLOR="#BC8F8F">'.'</FONT></B> || re[0]==*text)) - <B><FONT COLOR="#A020F0">return</FONT></B> matchhere(re+1, text+1); - <B><FONT COLOR="#A020F0">return</FONT></B> 0; -} - -<B><FONT COLOR="#228B22">int</FONT></B> <B><FONT COLOR="#0000FF">match</FONT></B>(<B><FONT COLOR="#228B22">char</FONT></B> *re, <B><FONT COLOR="#228B22">char</FONT></B> *text) { - <B><FONT COLOR="#A020F0">if</FONT></B> (re[0] == <B><FONT COLOR="#BC8F8F">'^'</FONT></B>) - <B><FONT COLOR="#A020F0">return</FONT></B> matchhere(re+1, text); - <B><FONT COLOR="#A020F0">do</FONT></B> { - <B><FONT COLOR="#A020F0">if</FONT></B> (matchhere(re, text)) - <B><FONT COLOR="#A020F0">return</FONT></B> 1; - } <B><FONT COLOR="#A020F0">while</FONT></B> (*text++ != <B><FONT COLOR="#BC8F8F">'\0'</FONT></B>); - <B><FONT COLOR="#A020F0">return</FONT></B> 0; -} - -<I><FONT COLOR="#B22222">/* - * Harness for testing with KLEE. - */</FONT></I> - -<I><FONT COLOR="#B22222">// The size of the buffer to test with. -</FONT></I>#<B><FONT COLOR="#5F9EA0">define</FONT></B> <FONT COLOR="#B8860B">SIZE</FONT> 7 - -<B><FONT COLOR="#228B22">int</FONT></B> <B><FONT COLOR="#0000FF">main</FONT></B>() { - <I><FONT COLOR="#B22222">// The input regular expression. -</FONT></I> <B><FONT COLOR="#228B22">char</FONT></B> re[SIZE]; - - <I><FONT COLOR="#B22222">// Make the input symbolic. -</FONT></I> klee_make_symbolic_name(re, <B><FONT COLOR="#A020F0">sizeof</FONT></B> re, <B><FONT COLOR="#BC8F8F">"re"</FONT></B>); - - <I><FONT COLOR="#B22222">// Try to match against a constant string "hello". -</FONT></I> match(re, <B><FONT COLOR="#BC8F8F">"hello"</FONT></B>); - - <B><FONT COLOR="#A020F0">return</FONT></B> 0; -} -</PRE> -<HR> -<ADDRESS>Generated by <A HREF="http://www.iki.fi/~mtr/genscript/">GNU enscript 1.6.4</A>.</ADDRESS> -</BODY> -</HTML> diff --git a/www/resources/get_sign.c.html b/www/resources/get_sign.c.html deleted file mode 100644 index 58c28d01..00000000 --- a/www/resources/get_sign.c.html +++ /dev/null @@ -1,37 +0,0 @@ -<!DOCTYPE html PUBLIC "-//IETF//DTD HTML 2.0//EN"> -<HTML> -<HEAD> -<TITLE>Enscript Output</TITLE> -</HEAD> -<BODY BGCOLOR="#FFFFFF" TEXT="#000000" LINK="#1F00FF" ALINK="#FF0000" VLINK="#9900DD"> -<A NAME="top"> -<A NAME="file1"> -<H1>get_sign.c</H1> - -<PRE> -<I><FONT COLOR="#B22222">/* - * First KLEE tutorial: testing a small function - */</FONT></I> - - -<B><FONT COLOR="#228B22">int</FONT></B> <B><FONT COLOR="#0000FF">get_sign</FONT></B>(<B><FONT COLOR="#228B22">int</FONT></B> x) { - <B><FONT COLOR="#A020F0">if</FONT></B> (x == 0) - <B><FONT COLOR="#A020F0">return</FONT></B> 0; - - <B><FONT COLOR="#A020F0">if</FONT></B> (x < 0) - <B><FONT COLOR="#A020F0">return</FONT></B> -1; - <B><FONT COLOR="#A020F0">else</FONT></B> - <B><FONT COLOR="#A020F0">return</FONT></B> 1; -} - -<B><FONT COLOR="#228B22">int</FONT></B> <B><FONT COLOR="#0000FF">main</FONT></B>() { - <B><FONT COLOR="#228B22">int</FONT></B> a; - klee_make_symbolic(&a, <B><FONT COLOR="#A020F0">sizeof</FONT></B>(a), <B><FONT COLOR="#BC8F8F">"a"</FONT></B>); - <B><FONT COLOR="#A020F0">return</FONT></B> get_sign(a); -} -</PRE> -<HR> -<ADDRESS>Generated by <A HREF="http://www.iki.fi/~mtr/genscript/">GNU Enscript 1.6.5.2</A>.</ADDRESS> -<I>enscript -Ec --color -w html get_sign.c -o get_sign.c.html</I> -</BODY> -</HTML> diff --git a/www/resources/islower.c.html b/www/resources/islower.c.html deleted file mode 100644 index 524f2093..00000000 --- a/www/resources/islower.c.html +++ /dev/null @@ -1,33 +0,0 @@ -<!DOCTYPE html PUBLIC "-//IETF//DTD HTML 2.0//EN"> -<HTML> -<HEAD> -<TITLE>Enscript Output</TITLE> -</HEAD> -<BODY BGCOLOR="#FFFFFF" TEXT="#000000" LINK="#1F00FF" ALINK="#FF0000" VLINK="#9900DD"> -<A NAME="top"> -<A NAME="file1"> -<H1>islower.c</H1> - -<PRE> -<I><FONT COLOR="#B22222">/* - * First KLEE tutorial: testing a small function - */</FONT></I> - -#<B><FONT COLOR="#5F9EA0">include</FONT></B> <B><FONT COLOR="#BC8F8F"><klee/klee.h></FONT></B> - -<B><FONT COLOR="#228B22">int</FONT></B> <B><FONT COLOR="#0000FF">my_islower</FONT></B>(<B><FONT COLOR="#228B22">int</FONT></B> x) { - <B><FONT COLOR="#A020F0">if</FONT></B> (x >= <B><FONT COLOR="#BC8F8F">'a'</FONT></B> && x <= <B><FONT COLOR="#BC8F8F">'z'</FONT></B>) - <B><FONT COLOR="#A020F0">return</FONT></B> 1; - <B><FONT COLOR="#A020F0">else</FONT></B> <B><FONT COLOR="#A020F0">return</FONT></B> 0; -} - -<B><FONT COLOR="#228B22">int</FONT></B> <B><FONT COLOR="#0000FF">main</FONT></B>() { - <B><FONT COLOR="#228B22">char</FONT></B> c; - klee_make_symbolic(&c, <B><FONT COLOR="#A020F0">sizeof</FONT></B>(c), <B><FONT COLOR="#BC8F8F">"input"</FONT></B>); - <B><FONT COLOR="#A020F0">return</FONT></B> my_islower(c); -} -</PRE> -<HR> -<ADDRESS>Generated by <A HREF="http://www.iki.fi/~mtr/genscript/">GNU enscript 1.6.4</A>.</ADDRESS> -</BODY> -</HTML> |