Git Product home page Git Product logo

aflat's People

Contributors

deforestt avatar faraja17 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

Forkers

gmh5225

aflat's Issues

Compatibility Mode

We need to create a mode that links the system malloc rather than any of the fun home-brewed stuff that we are used to. It should look like this in the aflat.cfg

set compatible 

it should link to a secondary {std file} file that does define any memory operations. Any secondary functions that are dependent on the specific memory function implementations should simply panic that they cannot be used in Compatibility Mode. the Function <function-name> is not supported in compatibility mode. Aborting. When compatibility mode is active, it will allow aflat to play nicely with the c standard library.

CMake migration

We will be migrating from make to CMake for better dependency control.

Overload functions

Overload functions should be allowed via name mangling. The first function should have the standard name functionName The subsequent functions should have the argument types prepended with dashes. functionName-int-adr-...

Implement Structures

A structure will define a list of dataTypes that make it up.
structures will be defined like so:
struct person {
char 20 firstName;
char age;
char 20 lastName;
int age;
};

when instantiated, the compiler should create a contiguous block of memory to hold the data.

Class Decoerators

A function should be able to be decorated with a class the same way that it can be decorated with another function. It should look like this.

class Decorator {
     adr foo = foo;
     Decorator init(adr foo){
          return my;
     };
     
    int run(adr args) {
         return my.foo(args);
     };
};

int decorated(adr args) : Decorator {
     return 0;
};

The decorator should create a dynamic const Object with the decorator passed into the constructor

CLArgs

Add a library to process command line args

Implicit Casting.

If a classes constructor takes only one argument, the AFlat compiler should be able to implicitly create an instance of the expected type.

for example

printString("Test String") -> printString(String("Test String"));

GDB Debugging

Add gdb debug symbols to output when in debug mode

Implement Enums

enums should work like in c, they should just be fancy constants. They should require a dot though we like to be explicit here.

enum colors { red, green, blue };

...
io.printInt(colors.red)

this should return 0;

Enums should be exportable or and importable classes.

Strange float suff

Floats do not behave correctly when certain functions are called. Need to investigate this. maybe the float registers have been muddied somewhere?

Function signatures hoisting.

Function signatures should be hoisted to the top of their scope.
This needs to happen after parsing in the lowering stage so that the function can be used throughout code generation.

`generic` type

There should be a new type called generic which is an adr, that cannot be implicitly cast.

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.