Skip to content

Feature/cd unit2#121

Open
roshankumar0036singh wants to merge 3 commits into
pushkarscripts:mainfrom
roshankumar0036singh:feature/cd-unit2
Open

Feature/cd unit2#121
roshankumar0036singh wants to merge 3 commits into
pushkarscripts:mainfrom
roshankumar0036singh:feature/cd-unit2

Conversation

@roshankumar0036singh
Copy link
Copy Markdown
Contributor

@roshankumar0036singh roshankumar0036singh commented May 21, 2026

Summary

This PR adds complete Unit 2: Syntax Analysis notes to the Compiler Design (CD) course under app/sem5/cd/. It follows the same architecture and component style as the existing Unit 1 content.


What's Covered (Exam Perspective)

  • Role of parser in compilation pipeline
  • CFGs: definition, derivations, parse trees
  • Ambiguity detection and grammar transformations (left-recursion elimination, left-factoring)
  • FIRST and FOLLOW set computation algorithms
  • LL(1) table construction and conflict rules
  • Shift-Reduce parsing: 4 actions, handles, handle pruning
  • LR(0) items, Closure, Goto operations
  • SLR(1) table construction rules and conflict types
  • LR(1) items with lookaheads, CLR vs LALR trade-offs
  • LALR conflict detection (Reduce/Reduce from core merging)
  • Ambiguity handling in Yacc/Bison, error recovery strategies
  • Solved problems with step-by-step tables for LL(1), SLR, LALR

- Add Ch7: Introduction to Syntax Analysis and CFGs
- Add Ch8: Top-Down Parsing and LL(1) Parsers
- Add Ch8 subtopic: LL(1) solved problem with table and trace
- Add Ch9: Bottom-Up Parsing and Shift-Reduce with themed diagram
- Add Ch10: LR(0) and SLR Parsing
- Add Ch10 subtopic: SLR solved problem with state DFA and trace
- Add Ch11: CLR(1) and LALR Parsing
- Add Ch11 subtopic: LALR solved problem with conflict proof
- Add Ch12: Ambiguity handling and error recovery
- Update constants.ts with chapters 7-12 and subtopics
- Update [chapter]/page.tsx to map all new components
@vercel
Copy link
Copy Markdown
Contributor

vercel Bot commented May 21, 2026

@roshankumar0036singh is attempting to deploy a commit to the PushkarScripts Team on Vercel.

A member of the Team first needs to authorize it.

@roshankumar0036singh
Copy link
Copy Markdown
Contributor Author

@pushkarscripts do check this one to when you are free

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant