Tim Chevalier
d60e08c18e
Eliminate explicit recursion in tstate.states (walk does that now),
...
and kill dead code.
2011-05-19 11:40:16 -07:00
Tim Chevalier
e1844d2719
Add ann as an argument to visit_fn
2011-05-19 11:40:16 -07:00
Tim Chevalier
6dcd607277
make trans compile
2011-05-19 11:40:16 -07:00
Tim Chevalier
a9bc6715e7
tidy tstate.collect_locals
2011-05-19 11:40:16 -07:00
Tim Chevalier
c0f728712b
Rewrite pre_postconditions to use walk instead of fold
2011-05-19 11:40:16 -07:00
Tim Chevalier
2cd769e358
Add ident as an argument to visit_fn (typestate wants it)
2011-05-19 11:40:16 -07:00
Tim Chevalier
ef5473deb1
Trim imports
2011-05-19 11:40:16 -07:00
Tim Chevalier
bb594a03a1
remove now-unused ts field from ann
2011-05-19 11:40:16 -07:00
Tim Chevalier
e16b097599
Rewrite tstate.annotate to use walk instead of fold
...
and various other tidying in typestate
2011-05-19 11:40:16 -07:00
Tim Chevalier
dc83c84662
Add visit_fn_pre and visit_fn_post fields to visitors
...
Added visit_fn_pre and visit_fn_post fields that get applied to
both regular functions and methods.
2011-05-19 11:40:16 -07:00
Tim Chevalier
ea1701de8c
Add a set_all function in bitv that's the inverse of clear
2011-05-19 11:40:16 -07:00
Tim Chevalier
8cbdaf4f93
Make trans use span_err for the dreaded "ty_var in trans::type_of" error
...
This required quite a bit of tiresome plumbing about of spans.
On the bright side, now other errors can be converted to span_err too.
Includes test cases.
2011-05-19 11:40:16 -07:00
Tim Chevalier
0d429a7603
add a bunch more logging things
2011-05-19 11:40:16 -07:00
Tim Chevalier
60399ed198
Tell Makefile to look an extra level deep for dependencies
2011-05-19 11:40:16 -07:00
Tim Chevalier
f909dd114d
Remove dead file (typestate_check is now a bunch of modules under middle/tstate)
2011-05-19 11:40:16 -07:00
Tim Chevalier
b624b43e47
Beginning of Operation Eliminate Folds
...
Started by rewriting collect_locals to use walk instead of fold
2011-05-19 11:40:16 -07:00
Tim Chevalier
4964023c5e
Fix an error message that reversed the expected and actual number of arguments in a pattern
2011-05-19 11:40:16 -07:00
Patrick Walton
6417610788
rustc: Generalize variable bindings so that we can use it for locals too
2011-05-19 11:14:44 -07:00
Marijn Haverbeke
c750c520e3
Remove rustboot-related logging hacks
...
(Also, feel free to start adding logging to your code. Really. It's fast.)
2011-05-19 19:33:32 +02:00
Patrick Walton
df90934bf7
rustc: Split write_* in typeck into versions that will record fixups
2011-05-18 19:19:20 -07:00
Patrick Walton
d2bdfe36cf
rustc: Don't inline free glue
2011-05-18 18:48:57 -07:00
Patrick Walton
c88fc06b40
rustc: Fix output name of optimized glue when --save-temps is on
2011-05-18 18:48:41 -07:00
Graydon Hoare
6f8b9e176f
Factor free paths out of drop glue, into free glue as in rustboot.
2011-05-18 17:28:08 -07:00
Patrick Walton
0aee8b3bd7
rustc: Thread statement contexts through unification
2011-05-18 15:36:14 -07:00
Rafael Ávila de Espíndola
bb7d4e15a8
Remove dead code.
2011-05-18 16:33:22 -04:00
Marijn Haverbeke
28c4a5586e
Start checking name collisions in modules
...
(And remove a boatload of duplicate imports from the typestate files.)
Name collision checking in local scopes will follow soon.
2011-05-18 22:24:20 +02:00
Rafael Ávila de Espíndola
843739ee98
A quick hack to get the bots green while I refactor this code.
2011-05-18 16:16:52 -04:00
Patrick Walton
13d9f6a264
rustc: Split out type variable fixups from unification
2011-05-18 13:08:54 -07:00
Rafael Ávila de Espíndola
96516e9ca2
One exit_task_glue to rule them all.
2011-05-18 15:43:48 -04:00
Graydon Hoare
6a4a85f452
Re-export CFG_LLVM_ROOT to reconfiguring.
2011-05-18 12:00:33 -07:00
Patrick Walton
37d5dd9471
rustc: Group the variable binding machinery into a separate data structure during unification
2011-05-18 11:54:12 -07:00
Rafael Ávila de Espíndola
a795d0e5b2
And yet more dead code.
2011-05-18 14:28:08 -04:00
Rafael Ávila de Espíndola
d108bfe2ee
Remove a bit more dead code.
2011-05-18 14:02:53 -04:00
Rafael Ávila de Espíndola
cebc9b359d
Remove dead rustboot code.
2011-05-18 13:48:57 -04:00
Patrick Walton
f4e049c415
rustc: Thread a statement context through the typechecker; use it for generating variable IDs. 40% typechecking speedup.
2011-05-17 22:21:31 -07:00
Graydon Hoare
49b90d37ed
Add mirror-all-snapshots.py script for extra crowdsourced backup power.
2011-05-17 22:06:55 -07:00
Patrick Walton
aed235e348
authors: Correct spelling of jrmuizel's name
2011-05-17 21:10:18 -07:00
Patrick Walton
ff1030b242
authors: Add Erick to AUTHORS
2011-05-17 21:10:02 -07:00
Patrick Walton
fdf8c49882
rustc: Don't rebuild the AST when typechecking statements
2011-05-17 21:09:34 -07:00
Patrick Walton
dc78544d36
Merge pull request #386 from erickt/master
...
Adding a simple vim indent file
2011-05-17 20:51:00 -07:00
Erick Tryzelaar
4d0cbd4310
Move vim syntax file, add indent file.
2011-05-17 20:35:46 -07:00
Patrick Walton
ace8058277
rustc: Have typechecking no longer rebuild the AST
2011-05-17 20:13:04 -07:00
Patrick Walton
df9801c9f0
rustc: Fix type mismatch in lib/sha1.rs constants
2011-05-17 20:13:03 -07:00
Brian Anderson
a98ea4f3ef
rustc: Run block cleanups on else if blocks
...
With the scheme used to translate 'else if' currently the if expression is
translated in a new (else) scope context. If that if expression wants to
result in a value that requires refcounting then it will need to drop the
refcount in the cleanups of the else block.
2011-05-17 22:25:24 -04:00
Patrick Walton
e840a37f33
rustc: Remove typeck::check_item_fn(); it's entirely superfluous!
2011-05-17 19:20:24 -07:00
Patrick Walton
87288a186d
rustc: Make check_const() not rebuild the AST (although it's not called at the moment!)
2011-05-17 19:13:16 -07:00
Patrick Walton
d21741843c
rustc: Make check_block not rebuild the AST
2011-05-17 19:10:24 -07:00
Patrick Walton
10503a4a02
rustc: Don't rebuild the AST when writing back locals
2011-05-17 19:00:29 -07:00
Patrick Walton
3ffe390570
rustc: Print the types of declarations in --typed-pretty mode
2011-05-17 19:00:16 -07:00
Patrick Walton
8637a4eaf3
rustc: Pull the type out of the correct expression when typechecking channel types. Puts out burning tinderbox.
2011-05-17 18:19:45 -07:00