nitlanguage
/
nit.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
test_parser: add option `-x` to output XML
[nit.git]
/
src
/
frontend
/
simple_misc_analysis.nit
diff --git
a/src/frontend/simple_misc_analysis.nit
b/src/frontend/simple_misc_analysis.nit
index
a50b45b
..
cc12d01
100644
(file)
--- a/
src/frontend/simple_misc_analysis.nit
+++ b/
src/frontend/simple_misc_analysis.nit
@@
-24,6
+24,7
@@
module simple_misc_analysis
import phase
redef class ToolContext
import phase
redef class ToolContext
+ # Execute `AModule::do_simple_misc_analysis` on each module.
var simple_misc_analysis_phase: Phase = new SimpleMiscAnalysisPhase(self, null)
end
var simple_misc_analysis_phase: Phase = new SimpleMiscAnalysisPhase(self, null)
end
@@
-58,11
+59,6
@@
private class SimpleMiscVisitor
do
toolcontext.warning(node.hot_location, tag, msg)
end
do
toolcontext.warning(node.hot_location, tag, msg)
end
-
- init(toolcontext: ToolContext)
- do
- self.toolcontext = toolcontext
- end
end
end
@@
-117,17
+113,7
@@
redef class AReturnExpr
end
end
end
end
-redef class AContinueExpr
- redef fun after_simple_misc(v)
- do
- var e = n_expr
- if e != null then
- e.warn_parentheses(v)
- end
- end
-end
-
-redef class ABreakExpr
+redef class AEscapeExpr
redef fun after_simple_misc(v)
do
var e = n_expr
redef fun after_simple_misc(v)
do
var e = n_expr