Y-asc

yet another stupid compiler
Log | Files | Refs | README | git clone https://git.ne02ptzero.me/git/Y-asc

commit 2207a65300d2f80d3b47a261ec4331f493a1adbb
Author: Ne02ptzero <louis@ne02ptzero.me>
Date:   Mon, 26 Jun 2017 17:48:05 +0200

First Commit

Diffstat:
AMakefile | 15+++++++++++++++
AREADME.md | 16++++++++++++++++
Aimg/logo.png | 0
Atex/yasc.tex | 126+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
4 files changed, 157 insertions(+), 0 deletions(-)

diff --git a/Makefile b/Makefile @@ -0,0 +1,15 @@ +NAME = yasc +TEX_DIR = tex/ + +all: ${NAME} + +${NAME}: + pdflatex -interaction=nonstopmode ${TEX_DIR}/${NAME}.tex + +clean: + rm -f *.aux *.log *.toc + +fclean: + rm -f ${NAME}.pdf + +re: fclean all diff --git a/README.md b/README.md @@ -0,0 +1,16 @@ +<p align="center"> +<img src="https://raw.githubusercontent.com/Ne02ptzero/Y-asc/master/img/logo.png" /><br /> +<h3>Yet Another Stupid Compiler</h3> +</p> + + +# Build +## Requirements +``` +LateX +``` + +## Generate PDF +``` +make +``` diff --git a/img/logo.png b/img/logo.png Binary files differ. diff --git a/tex/yasc.tex b/tex/yasc.tex @@ -0,0 +1,126 @@ +\documentclass{scrartcl} +\usepackage[utf8]{inputenc} +\usepackage{graphicx} +\usepackage{geometry} +\usepackage{titling} + +% Configuration +\graphicspath{ {img/} } +\geometry{a4paper} + +\renewcommand\partheadstartvskip{\clearpage\null\vfil} +\renewcommand\partheadmidvskip{\par\nobreak\vskip 20pt\thispagestyle{empty}} +\renewcommand\partheadendvskip{\vfil\clearpage} +\renewcommand\raggedpart{\centering} + + +% Title +\title{Yet Another Stupid Compiler} +\author{ + Louis Solofrizzo\\ + \texttt{louis@ne02ptzero.me}\\ + \\ + 42 Staff\\ + \texttt{staff@42.fr} +} + +\pretitle{% + \begin{center} + \LARGE + \includegraphics[scale=0.1, height=7cm]{logo}\\[\bigskipamount] +} + +\posttitle{% + \end{center} +} + + +% Actual document +\begin{document} + +\begin{titlingpage} + \maketitle +\end{titlingpage} + + + \tableofcontents{} + \newpage + +\part{Introduction} +\part{The Y Language} + \section{Getting Started} + \section{Types, Operators and Expressions} + \subsection{Variable names} + \subsection{Namespaces} + \subsection{Data types and Sizes} + \subsection{Constants} + \subsection{Declarations} + \subsection{Arithmetic Operators} + \subsection{Type Conversions} + \subsection{Assignement Operators and Expressions} + \subsection{Conditionnal Expressions} + \subsection{Precedence and Order of Evaluation} + \section{Control Flow} + \subsection{If-Else} + \subsection{Else-If} + \subsection{Loops - While} + \subsection{Loops - For} + \subsection{Loops - Do-While} + \subsection{Break and Continue} + \section{Functions and Program Structure} + \subsection{Basics} + \subsection{External Variables} + \subsection{Scope Rules} + \subsection{Header Files} + \subsection{Static Variables} + \subsection{Recursion} + \subsection{Preprocessor} + \section{Pointers and Arrays} + \subsection{Pointers and Addresses} + \subsection{Pointers and Function Arguments} + \subsection{Pointers and Arrays} + \subsection{Address Arithmetic} + \subsection{The \_\_heap argument} + \subsection{Command-line Arguments} + \section{Structures} + \subsection{Basics} + \subsection{Structures and Functions} + \subsection{Array of Structures} + \subsection{Pointer to Structures} + \subsection{Packing} + \section{Standard Library} + \subsection{Input and Output} + \subsection{Memory Control} + \subsection{System Calls} + \section{Format} + \subsection{Comments} + \subsection{Unicode} + \subsection{Inline definitions} +\part{The ASC Language} + \section{Getting Started} + \section{Definitions} + \section{Accessors} + \subsection{Basics} + \subsection{Special Accessors} + \subsection{Constants} + \section{Registers} + \subsection{Infinite Registers} + \subsection{Define a Register} + \section{Memory} + \subsection{Virtual Memory} + \subsection{Paging} + \subsection{On-Disk memory} + \subsection{Cache} + \section{Arithmetic} + \subsection{Basics} + \subsection{Comparisons} + \subsection{Bit-Fields} + \section{Calls} + \subsection{Functions} + \subsection{System Calls} + \section{Format} + \subsection{Comments} + \subsection{Instructions} + + +\end{document}