zik.saleeba
f1aeadb077
Removed redundant "struct ArrayValue"
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@369 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-11-01 21:10:48 +00:00
zik.saleeba
18acb6dc1a
Removed old pointer system. Now it's "native pointers" all the way.
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@368 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-11-01 21:02:31 +00:00
zik.saleeba
24a601271a
malloc() and free() implemented.
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@346 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-10-25 20:50:56 +00:00
zik.saleeba
c6d483ee6f
Unsigned types now exist. They're probably not handled quite correctly in expressions yet though.
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@345 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-10-25 11:54:34 +00:00
zik.saleeba
8c7434424d
Native pointers no longer carry their size with them.
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@344 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-10-23 19:01:32 +00:00
zik.saleeba
0d83e26880
Correct alignment of structure members
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@341 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-10-11 18:55:16 +00:00
zik.saleeba
196331d6ba
'short' data type added
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@340 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-10-11 11:09:07 +00:00
zik.saleeba
8e735ef68f
First cut of casts completed but not debugged
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@338 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-10-10 17:59:55 +00:00
zik.saleeba
7d135bbdd5
Doing some work on casts and sizeof
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@337 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-10-10 14:49:49 +00:00
zik.saleeba
32727cc365
Native pointers feature added
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@331 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-06-05 00:55:54 +00:00
zik.saleeba
637e224fff
Now parses but ignores signed/unsigned declarations
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@325 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-06-03 02:31:43 +00:00
zik.saleeba
eb6f323f06
HeapAlloc() changed to HeapAllocMem() to avoid clash with win32 namespace.
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@321 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-06-02 08:00:02 +00:00
zik.saleeba
bb0d19a733
Now conforms fully to the ISO C90 standard
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@320 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-06-02 07:50:46 +00:00
zik.saleeba
825c393240
Reworking of how assignment works. Now all places which do assignment of values
...
should work the same.
git-svn-id: http://picoc.googlecode.com/svn/trunk@314 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-06-02 05:51:51 +00:00
zik.saleeba
5dcde3d5ea
Fix for a bug where variables which were initialised on declaration weren't writable.
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@279 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-05-14 00:21:29 +00:00
zik.saleeba
a76fc34881
By popular demand I'm adding support for native pointers. It's a work in progress - not working yet.
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@277 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-05-06 00:25:09 +00:00
zik.saleeba
997f0c119f
Fixed a char * arithmetic bug
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@273 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-04-29 03:24:15 +00:00
zik.saleeba
c805b3fdec
Added ability to print types in error messages
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@268 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-04-24 01:02:25 +00:00
zik.saleeba
95f2b3e193
Characters are now actually stored as char and coerced to other types when necessary.
...
Parameters are passed as the requested types and coerced where appropriate.
Assignments are now a function rather than a macro.
Cleaned up some comments in lex.c.
Small valued integer constants are passed as char constants to save space.
git-svn-id: http://picoc.googlecode.com/svn/trunk@262 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-04-22 12:06:58 +00:00
zik.saleeba
e5fa7017f0
Better checks on pointers.
...
Pointer offsets are now honoured.
git-svn-id: http://picoc.googlecode.com/svn/trunk@259 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-04-22 07:23:26 +00:00
zik.saleeba
61174fb115
Interactive mode error handling fixed for surveyor.
...
All surveyor warnings fixed.
git-svn-id: http://picoc.googlecode.com/svn/trunk@216 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-04-04 03:11:12 +00:00
zik.saleeba
48a6472c68
All allocations are now cleaned up neatly on exit. This is probably unnecessary given that we run our own heap but gives confidence that there are no internal memory leaks.
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@199 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-03-11 23:49:10 +00:00
zik.saleeba
6f7daf0145
Now cleaning up types too
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@195 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-03-11 10:17:46 +00:00
zik.saleeba
23bce9d38a
enums implemented
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@180 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-03-09 22:36:01 +00:00
zik.saleeba
dc04ba8dd0
Split parsing across two files parse.c and the new expression.c
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@170 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-03-08 07:56:28 +00:00
zik.saleeba
3bdbb51d5c
Now allowing multiple declarations in one statement
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@157 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-03-06 06:00:51 +00:00
zik.saleeba
676c937a7b
Fixed bug in stdarg handling of non-stack values
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@142 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-03-02 22:13:47 +00:00
zik.saleeba
73d91b6202
Change to add extra lvalue information to values
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@117 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-02-26 09:56:22 +00:00
zik.saleeba
cf28c7513c
Fixed some inconsistencies in array handling
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@105 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-02-24 02:28:35 +00:00
zik.saleeba
e94767ba98
New NO_FP compile option allows removal of all floating point support
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@101 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-02-24 00:21:17 +00:00
zik.saleeba
93a6a0e9d0
Fixed a bug in array allocation (regression)
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@100 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-02-24 00:08:11 +00:00
zik.saleeba
7f6503d1e0
printf() now works!
...
Fixed a bug in pointer sizing.
git-svn-id: http://picoc.googlecode.com/svn/trunk@98 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-02-21 12:02:15 +00:00
zik.saleeba
4821d689ad
Big changes to string constants.
...
Got rid of str.c.
First attempt at stdarg params in printf()
git-svn-id: http://picoc.googlecode.com/svn/trunk@97 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-02-21 02:35:52 +00:00
zik.saleeba
fdad9f8d30
Changes to help with implementing switch/case/break/continue/return
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@82 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-02-18 08:19:06 +00:00
zik.saleeba
b073f187f8
Revamped the way lvalues work. Now both structs and '.' should work.
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@77 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-02-15 05:52:03 +00:00
zik.saleeba
51afc538be
struct are now working
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@69 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-02-10 08:42:09 +00:00
zik.saleeba
bd30654f74
Fixed a problem with VariableAllocValueAndData() allocating the wrong amount of memory.
...
Fixed a problem with type parsing.
git-svn-id: http://picoc.googlecode.com/svn/trunk@62 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-02-03 10:39:48 +00:00
zik.saleeba
c009864bbb
Fixed type parsing error
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@60 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-02-03 00:46:02 +00:00
zik.saleeba
956efab67f
Parser is now updated to work with the new lexer and string system.
...
System now compiles - needs debug.
git-svn-id: http://picoc.googlecode.com/svn/trunk@48 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-02-02 11:08:36 +00:00
zik.saleeba
f8216bb79f
Type system now works with the new lexer.
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@47 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-02-02 05:27:15 +00:00
zik.saleeba
b2396d3eda
Now stack frames appear on our new stack as they should. The old static
...
limits are gone.
git-svn-id: http://picoc.googlecode.com/svn/trunk@40 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-01-29 11:10:46 +00:00
zik.saleeba
75e45704e8
Bulk changes to accomodate the new storage model.
...
The system now compiles again (probably doesn't run though).
git-svn-id: http://picoc.googlecode.com/svn/trunk@38 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-01-26 08:57:32 +00:00
zik.saleeba
4524270e50
Changing everything to handled heap-allocated values
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@37 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-01-25 02:09:44 +00:00
zik.saleeba
b9e1086cbb
Moving towards a working new type system
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@36 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-01-24 03:15:02 +00:00
zik.saleeba
fad5c6db69
Big changes and progress towards the new type system. Doesn't compile right now. Maybe tomorrow.
...
git-svn-id: http://picoc.googlecode.com/svn/trunk@35 21eae674-98b7-11dd-bd71-f92a316d2d60
2009-01-23 11:34:12 +00:00