Giter VIP home page Giter VIP logo

c--lang's People

Contributors

lesliem98 avatar lraubuch avatar

c--lang's Issues

Method call

The compiler should execute the correct method when calling an identifier with the given parameters.

  • Implemented
  • Tested

Structs

The compiler should be able to handle basic structs like seen in C but without the typedef. a struct keyword is enough to define a new type.

  • Implemented
  • Tested

Basic arithmetic

The compiler should be able to handle:

  • dvision / integer divison
  • multiplication
  • addition
  • subtraction

  • Implemented
  • Tested

Variables

The compiler should be able to handle variables in their corresponding scope.

  • Definition Recognition
  • Implemented
  • Tested

Correct Parantheses Handling

The compiler should be able to handle arithmetic operations according to the parantheses used in the expression.

  • Implemented
  • Tested

Loop

The compiler should handle a basic while loop loop(condition) { ... }. One liner loops should be supported.
The loop should behave like the common while loop

  • Implemented
  • Tested

Constants

The compiler should be able to substitute constant names to their actual value literals before compiling.

  • Definition recognition
  • Replacement
  • Implemented
  • Tested

Function-overloading

The compiler should be able to distinguish between the defined arguments of a function

  • Implemented
  • Tested

Boolean arithmetic

The compiler should be able to handle:

  • NOT (!)
  • AND (&&)
  • OR (||)
  • greater than (>)
  • less than (<)
  • greater or equal (>=)
  • smaller or equal(<=)
  • equals (==)
  • not equals (!=)

  • Implemented
  • Tested

Scopes

The compiler should be able to distinguish between local scope and global scope variables.

  • Implement
  • Test

Main function

Write the main function of the program so a user can later compile stuff from the cli

Print method for language

The language should support a statement that prints simple text onto the terminal.

  • Implemented
  • Tested

  • println(num n)
  • println(123)

Method definition

The compiler should be able to define a method before actually executing the function call.

  • Implemented
  • Tested

Identifier

Make it possible to use non-literals in any expression or statement. f.e. in function calls.

  • Implemented
  • Tested

If-Else

The compiler should handle the basic if-else structure f.e. if(condition) { ... } else { ... } with or without else branch, also one liners should be supported.

  • Implemented
  • Tested
    We also want to be able to handle nested If-Else Statements:
  • Implemented
  • Tested

Arrays

The Compiler should be able to handle Arrays.

  • Implemented
  • Tested

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.