Skip to content

Commit

Permalink
checkpoint (post a2)
Browse files Browse the repository at this point in the history
  • Loading branch information
SantriptaSharma committed Oct 18, 2023
1 parent 08fe105 commit 9809c40
Show file tree
Hide file tree
Showing 12 changed files with 7 additions and 4 deletions.
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,6 @@ lexer.c
*.zip

# redundant files
*_old.*
*_old.*

tex_build/../15_*.pdf
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Empty file added 15_A3.y
Empty file.
File renamed without changes.
Binary file added A3.pdf
Binary file not shown.
5 changes: 3 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,15 +1,16 @@
CC=gcc
l=flex
CFLAGS=-Wall -Wextra -Werror -pedantic -std=c11

o=lexer

team=recursive-dissent
team=15
assignment=2

build: clean $(o)

$(o): $(o).c
$(CC) -o $(o) $^ $(team)_A$(assignment).c
$(CC) $(CFLAGS) -o $(o) $^ $(team)_A$(assignment).c

$(o).c: $(team)_A$(assignment).l
$(l) -o$(o).c $^
Expand Down
2 changes: 1 addition & 1 deletion expected.out
Original file line number Diff line number Diff line change
@@ -1 +1 @@
<KEYWORD, int>, <IDENT, a>, <PUNCT, =>, <CONST, 341>, <PUNCT, ;>, <KEYWORD, int>, <IDENT, b>, <PUNCT, =>, <CONST, 0213>, <PUNCT, ;>, <KEYWORD, int>, <IDENT, c>, <PUNCT, =>, <CONST, -123>, <PUNCT, ;>, <KEYWORD, int>, <IDENT, d>, <PUNCT, =>, <PUNCT, ->, <CONST, 00045>, <PUNCT, ;>, <KEYWORD, int>, <IDENT, _valididentifier_>, <PUNCT, =>, <CONST, +1>, <PUNCT, ;>, <KEYWORD, int>, <PUNCT, *>, <IDENT, ptr>, <PUNCT, =>, <PUNCT, &>, <IDENT, d>, <PUNCT, ;>, <KEYWORD, int>, <PUNCT, *>, <IDENT, ptrptr>, <PUNCT, =>, <PUNCT, &>, <IDENT, ptr>, <PUNCT, ;>, <PUNCT, *>, <PUNCT, *>, <IDENT, ptr>, <PUNCT, +>, <PUNCT, +>, <PUNCT, ;>, <IDENT, ptr>, <PUNCT, ->>, <IDENT, addr>, <PUNCT, (>, <PUNCT, )>, <PUNCT, ;>, <KEYWORD, if>, <PUNCT, (>, <IDENT, name1>, <PUNCT, ==>, <STRLIT, "3454\n">, <PUNCT, )>, <PUNCT, {>, <KEYWORD, return>, <CONST, 'abc'>, <PUNCT, ;>, <PUNCT, }>, <KEYWORD, void>, <IDENT, identifierguy>, <PUNCT, (>, <KEYWORD, int>, <IDENT, x>, <PUNCT, =>, <CONST, -31>, <PUNCT, )>, <PUNCT, {>, <KEYWORD, if>, <PUNCT, (>, <IDENT, x>, <PUNCT, ==>, <CONST, -31>, <PUNCT, )>, <PUNCT, {>, <KEYWORD, return>, <PUNCT, ;>, <PUNCT, }>, <KEYWORD, else>, <PUNCT, {>, <KEYWORD, for>, <PUNCT, (>, <PUNCT, ;>, <PUNCT, ;>, <PUNCT, )>, <PUNCT, {>, <IDENT, printf>, <PUNCT, (>, <STRLIT, "aaaaaaaaaaaaaaaaaaaaa">, <PUNCT, )>, <PUNCT, ;>, <PUNCT, }>, <PUNCT, }>, <PUNCT, }>, <STRLIT, "weirdo stringliteral /*hopefully not a comment*/ \n \n \n \n ">, <CONST, 1>, <PUNCT, *>, <PUNCT, />, <IDENT, asdipoi>, <IDENT, a>, <IDENT, works>, <IDENT, hopefully>, <IDENT, these>, <IDENT, are>, <IDENT, idents>, <PUNCT, *>, <PUNCT, />, <STRLIT, "string literal">, <IDENT, not>, <IDENT, anymore>,
<KEYWORD, int>, <IDENT, a>, <PUNCT, =>, <CONST, 341>, <PUNCT, ;>, <KEYWORD, int>, <IDENT, b>, <PUNCT, =>, <CONST, 0213>, <PUNCT, ;>, <KEYWORD, int>, <IDENT, c>, <PUNCT, =>, <CONST, -123>, <PUNCT, ;>, <KEYWORD, int>, <IDENT, d>, <PUNCT, =>, <PUNCT, ->, <CONST, 00045>, <PUNCT, ;>, <KEYWORD, int>, <IDENT, _valididentifier_>, <PUNCT, =>, <CONST, +1>, <PUNCT, ;>, <IDENT, swap>, <IDENT, top>, <KEYWORD, int>, <PUNCT, *>, <IDENT, ptr>, <PUNCT, =>, <PUNCT, &>, <IDENT, d>, <PUNCT, ;>, <KEYWORD, int>, <PUNCT, *>, <IDENT, ptrptr>, <PUNCT, =>, <PUNCT, &>, <IDENT, ptr>, <PUNCT, ;>, <PUNCT, *>, <PUNCT, *>, <IDENT, ptr>, <PUNCT, +>, <PUNCT, +>, <PUNCT, ;>, <IDENT, ptr>, <PUNCT, ->>, <IDENT, addr>, <PUNCT, (>, <PUNCT, )>, <PUNCT, ;>, <KEYWORD, if>, <PUNCT, (>, <IDENT, name1>, <PUNCT, ==>, <STRLIT, "3454\n">, <PUNCT, )>, <PUNCT, {>, <KEYWORD, return>, <CONST, 'abc'>, <PUNCT, ;>, <PUNCT, }>, <KEYWORD, void>, <IDENT, identifierguy>, <PUNCT, (>, <KEYWORD, int>, <IDENT, x>, <PUNCT, =>, <CONST, -31>, <PUNCT, )>, <PUNCT, {>, <KEYWORD, if>, <PUNCT, (>, <IDENT, x>, <PUNCT, ==>, <CONST, -31>, <PUNCT, )>, <PUNCT, {>, <KEYWORD, return>, <PUNCT, ;>, <PUNCT, }>, <KEYWORD, else>, <PUNCT, {>, <KEYWORD, for>, <PUNCT, (>, <PUNCT, ;>, <PUNCT, ;>, <PUNCT, )>, <PUNCT, {>, <IDENT, printf>, <PUNCT, (>, <STRLIT, "aaaaaaaaaaaaaaaaaaaaa">, <PUNCT, )>, <PUNCT, ;>, <PUNCT, }>, <PUNCT, }>, <PUNCT, }>, <STRLIT, "weirdo stringliteral /*hopefully not a comment*/ \n \n \n \n ">, <CONST, 1>, <PUNCT, *>, <PUNCT, />, <IDENT, asdipoi>, <IDENT, a>, <IDENT, works>, <IDENT, hopefully>, <IDENT, these>, <IDENT, are>, <IDENT, idents>, <PUNCT, *>, <PUNCT, />, <STRLIT, "string literal">, <IDENT, not>, <IDENT, anymore>,
Binary file renamed recursive-dissent_A2.pdf → tex_build/15_A2.pdf
Binary file not shown.
Binary file removed tex_build/recursive-dissent_A2.pdf
Binary file not shown.

0 comments on commit 9809c40

Please sign in to comment.