Giter VIP home page Giter VIP logo

sim-c's Introduction

sim-C

GitHub GitHub stars GitHub contributors PRs Welcome GitHub last commit GitHub issues GitHub closed issues GitHub closed pull requests

Hacktoberfest 2020

Hacktoberfest 2020 is here. Contributions are now welcome. Please go through CONTRIBUTING.md and the instructions in readme Contribute. We look forward for your contributions.

What is sim-C?

Often people have trouble programming in C (especially beginners) due to its low level syntax and unavailability of stable third party libraries. We present sim-C a high-level front end for C which creates a dynamically typed syntax for C. User can write code in this high level syntax and then compile it to optimized C code. sim-C does not process the code and simply translates it to C thus, there is no possibility of the code running slowly. So, with sim-C users can write code faster using the high level syntax and at the same time be able to harness the power and speed of a C program. Let us make C cool again.

Pipeline

Start Contributing

sim-C which has a highly intuitive codebase, you'll be ready to contribute in no time! While adding any functionality to sim-C you need to make changes in the following files only:

1. lexical_analyzer.py Lexical analysis is the first phase of a compiler. It takes the modified source code from language preprocessors that are written in the form of sentences. The lexical analyzer breaks these syntaxes into a series of tokens, by removing any whitespace or comments in the source code. Depending on the type of functionality add it to the respective function: is_keyword, numeric_val, string_val, keyword_identifier and/or lexical_analyze.

2. op_code.py It is responsible for creating opcodes. If need be you need to change the opcode2dig function only which returns the integer representation of opcode type.

3. simc_parser.py Parser is an interpreter component that is used to break the data into smaller elements coming from lexical analysis phase. A parser takes input in the form of sequence of tokens and produces output. Here you may need to create a separate function which defines the grammar and checks for the syntax. The function should return the OpCode. Also, if need be you have to append the functionality to the parse function which parses the tokens, calls the particular function and returns opcodes.

4. compiler.py Finally you need to define the opcode type in the compiler and write the expected C syntax for the functonality.

You can write a test in test.simc and verify whether it's producing results in the test.c file.

Contributing

To get started with simC follow the official documentation:- https://cimplec.github.io/docs/

The following resources are a good place to get to know more about simC:-

  1. Writing code in C? Simplify your life with sim-C Dev.to, Medium.
  2. Getting Started with sim-C Dev.to, Medium.

Apart from these blog posts, you can also checkout the official docs.

Instructions for first time contributors/beginner level contributors for question related issues during HACKTOBERFEST

  • Start working on the issues once you are assigned to them. Head over to the issue and comment that you want it to be assigned to you. Once the maintainer assigns the issue to you, start working on it. Issues will be assigned on a First Come First Serve (FCFS) basis.
  • Once the issue is assigned, you have one week (7 Days) to submit the PR. Failing to do so will get the issue reassigned to someone else. As each issue related to questions are being assigned to single contributor at a time, we sincerely hope that you cooperate with us.
  • If you create a PR without the issue being assigned to you, the PR will be marked spam as you are not adhering to the rules.
  • The simC code that you write has to placed in the location simc-codes directory. If not found in the right place, our maintainers would write a comment to the PR as a warning and if the correct location is still not provided on the resubmission, the PR would be marked spam for not adhering to the rules.

Before moving further please go through the rules in CONTRIBUTING.md

License

sim-C is licensed under GNU General Public License (GPL) v3.0. LICENSE

The Team

Featured Contributors

List of contributors who contributed in some features or major bugs of simC (This list is not ordered by significance of contribution, every contribution is equally valuable for us):-

sim-c's People

Contributors

aayush-99 avatar abhisinha2001 avatar asmitraj05 avatar bruhbs avatar darshit-sopho avatar devlokcodes avatar dhairyaj avatar dmte avatar frankhart2018 avatar gursimranheer avatar heisastark avatar himanshisinghal09 avatar kunal1197 avatar laddhashreya2000 avatar martianmellow12 avatar nanoy42 avatar nishitjain1204 avatar pranshuldobriyal avatar priyanshu-official avatar puranjaymohan avatar rahulhambarde300 avatar reveurguy avatar roysti10 avatar shaheer-rossoneri14 avatar siddharthaml avatar suraj-shivu avatar vincent-vimard avatar vnksnkr avatar vsawal avatar yjdoc2 avatar

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.