[Compiler] Implemented basic code generation
Needs ReviewPublic

Authored by jangmarker on Sep 12 2015, 10:38 AM.

Details

Reviewers
akreuzkamp
pavelvasev
Maniphest Tasks
Restricted Maniphest Task
Summary

RevampIR - changes in object tree and in type system.
Code generator for new object tree and type system.
Code generator example usages in testprettygeneratorpass.cpp

Closes T504

Diff Detail

Repository
R18 QMLWeb
Branch
feature/revampIR
Lint
No Linters Available
Unit
No Unit Test Coverage
pavelvasev updated this revision to Diff 864.Sep 12 2015, 10:38 AM
pavelvasev retitled this revision from to [Compiler] Implemented basic code generation Closes T504.
pavelvasev updated this object.
pavelvasev edited the test plan for this revision. (Show Details)
pavelvasev added reviewers: akreuzkamp, jangmarker.
akreuzkamp retitled this revision from [Compiler] Implemented basic code generation Closes T504 to [Compiler] Implemented basic code generation.Sep 12 2015, 10:52 AM
akreuzkamp updated this object.
akreuzkamp added a task: Restricted Maniphest Task.
akreuzkamp edited edge metadata.Nov 14 2015, 12:56 PM

that should do it for now :)

Jan will take care of fixing these :)

src/qmljsc/ir/file.h
41

I don't think these comments belong here. Rather add tasks for it in Phabricator.

src/qmljsc/ir/objecttree.h
61

coding style

62

This isn't a plain old datatype. Thus we should make it a class and add getters for the members (we already have setters which is assignSth).

64

coding style (parameter name)

77

use union for the values and an additional type enum. As we need some type flag anyway (bListAssigned) we don't gain anything from how we do it now.

94

add const and rename to hasSth()

101

same thing, transform to class.

120

There's no need to discuss this. We can remove that comment. :)
(ids *are no* properties. ;) )

124

m_parentInObjectTree

130

Nice! :)

134

make private

138

make private

144

protected -> private

src/qmljsc/ir/typesystem.cpp
182

remove :)

src/qmljsc/ir/typesystem.h
58

It's two different things. ObjectSpec::rootObject means "I am a component". This is not meant to be set by components but only by that one type "Component" (from which all components derive). But I see, we need to rename that flag.

93

whitespace

105

coding style

122

If it should be AST, why isn't it? :D

147

remove

158

They can now be found in builtintypes.h, so we should remove that here :)

jangmarker commandeered this revision.Nov 14 2015, 12:56 PM
jangmarker edited reviewers, added: pavelvasev; removed: jangmarker.