nitlanguage
/
nit.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
compiler: remove services for deprecated calloc_array
[nit.git]
/
src
/
rapid_type_analysis.nit
diff --git
a/src/rapid_type_analysis.nit
b/src/rapid_type_analysis.nit
index
42a757b
..
88e2b7e
100644
(file)
--- a/
src/rapid_type_analysis.nit
+++ b/
src/rapid_type_analysis.nit
@@
-132,7
+132,7
@@
class RapidTypeAnalysis
var types = typeset.to_a
(new CachedAlphaComparator).sort(types)
var res = new CsvDocument
var types = typeset.to_a
(new CachedAlphaComparator).sort(types)
var res = new CsvDocument
- res.format = new CsvFormat('"', ';', "\n")
+ res.separator = ';'
res.header = ["Type", "Resolution", "Liveness", "Cast-liveness"]
for t in types do
var reso
res.header = ["Type", "Resolution", "Liveness", "Cast-liveness"]
for t in types do
var reso
@@
-255,6
+255,8
@@
class RapidTypeAnalysis
add_cast(paramtype)
end
add_cast(paramtype)
end
+ if mmethoddef.is_abstract then continue
+
var npropdef = modelbuilder.mpropdef2node(mmethoddef)
if npropdef isa AClassdef then
var npropdef = modelbuilder.mpropdef2node(mmethoddef)
if npropdef isa AClassdef then
@@
-314,7
+316,9
@@
class RapidTypeAnalysis
if not check_depth(rt) then continue
#print "{ot}/{t} -> {rt}"
live_types.add(rt)
if not check_depth(rt) then continue
#print "{ot}/{t} -> {rt}"
live_types.add(rt)
- todo_types.add(rt)
+ # unshift means a deep-first visit.
+ # So that the `check_depth` limit is reached sooner.
+ todo_types.unshift(rt)
end
end
#print "MType {live_types.length}: {live_types.join(", ")}"
end
end
#print "MType {live_types.length}: {live_types.join(", ")}"