Comments (3)
id->class is 0 for passed parameters vs. class 'Par' or 'Loc'. There may be other inconsistencies for other storage types.
Can you make a list of proposed changes to improve the consistency?
from amacc.
Yes. I may pick up this ticket in the next few weeks. There is a lot of detail work to make everything consistent. It probably won't be a lot of code changes (15-30 lines?), but I (or whoever takes this on) will have to check every corner of the code to make sure they have it right. After it is done though, it will greatly increase the power of working with class-types, and maybe types in general.
from amacc.
The issue is that id->class needs to be (1) set to non-zero when an identifier is defined/instantiated and (2) zero valued when an identifier is referenced but not yet instantiated/defined. This knowledge is especially useful in a one pass compiler like AMACC when generating IR. For instance, Labels can be used by goto statements before the Label appears in the source code stream.
from amacc.
Related Issues (20)
- AssertionError: shift operations HOT 3
- How left shift handles negative number? HOT 1
- Remove the presence of global *e HOT 3
- Improve portability by adding ssize_t and long types
- Reorder opcode enumeration HOT 1
- Incorrect execution result for simple program HOT 2
- Modulo (operator%) does not give correct result HOT 2
- Can't create elf file directly on ARM? HOT 9
- Calling convention documentation? HOT 1
- Can the codegen() for IR instruction CLCA be removed? HOT 3
- Consider adding static storage class? HOT 4
- Allow array declarations using [] operators. HOT 2
- Enhance robustness of '[ ]' operator for array access. HOT 2
- Can't create ELF executable from bootstrap amacc compiler
- Add floating point type? HOT 3
- Add support for struct assignement.
- Compound assign operators don't work with struct member lvalues HOT 1
- bad dereference compiler error HOT 1
- Simple program breaks the compiler HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from amacc.