]> git.uio.no Git - ifi-stolz-refaktor.git/blob - presentation/bh15.tex
Slides
[ifi-stolz-refaktor.git] / presentation / bh15.tex
1 % Law of demeter?
2 \documentclass[USenglish,9pt]{beamer}
3 \usepackage[utf8]{inputenc}
4 \usepackage[T1]{fontenc}
5 \usepackage{lmodern}
6 \usepackage{babel,textcomp}
7 \usepackage[style=alphabetic,backend=biber,doi=false,isbn=false]{biblatex}
8 \usepackage{babel,textcomp,csquotes}
9 \usepackage{xspace}
10 \usepackage{tabularx}
11 \usepackage{booktabs}
12
13 \usepackage{tikz}
14 \usetikzlibrary{shapes,snakes,trees,arrows,shadows,positioning,calc}
15
16 \usepackage{varioref}
17 %\usepackage[hidelinks]{hyperref}
18 \usepackage{cleveref}
19
20 \usepackage{amsthm}
21 \usepackage{mathtools}
22
23 \usepackage{verbatim}
24 \usepackage{minted}
25 \usepackage{multicol}
26 %\usemintedstyle{bw}
27 \usemintedstyle{default}
28
29 \usetheme{Ifi}
30
31 \theoremstyle{definition}
32 \newtheorem*{wordDef}{Definition}
33 \newtheorem*{mytheorem}{Theorem}
34 \newcommand{\mydefinition}[1]{\begin{wordDef}#1\end{wordDef}}
35
36 \newcommand{\citing}[1]{~\cite{#1}}
37
38 \newcommand{\code}[1]{\texttt{\textbf{#1}}}
39 \newcommand{\type}[1]{\code{#1}}
40 \newcommand{\method}[1]{\type{#1}}
41 \newcommand{\var}[1]{\type{#1}}
42
43 \newcommand{\name}[1]{#1}
44 \newcommand{\tit}[1]{\emph{#1}}
45 \newcommand{\refa}[1]{\emph{#1}}
46 \newcommand{\pattern}[1]{\emph{#1}}
47 \newcommand{\metr}[1]{\emph{#1}}
48 \newcommand{\ExtractMethod}{\refa{Extract Method}\xspace}
49 \newcommand{\MoveMethod}{\refa{Move Method}\xspace}
50 \newcommand{\ExtractAndMoveMethod}{\refa{Extract and Move Method}\xspace}
51
52 \newcommand{\mysection}[1]{
53   \section{#1}
54   \begin{frame}
55     \begin{center}{\Huge #1}\end{center}
56   \end{frame}
57 }
58
59 \def\mintedframesep{11pt}
60
61 \def\thetitle{Search-based Composed Refactorings}
62 \def\subtitle{Implementing and evaluating a search-based Extract and Move Method refactoring}
63 \title{\thetitle}
64 \author{Erlend Kristiansen, Volker Stolz}
65
66
67 %% HEADLINE %%
68 \setbeamertemplate{headline}{%
69   \ifnum\insertframenumber>1
70 \leavevmode%
71   \hbox{%
72     \begin{beamercolorbox}[wd=\paperwidth,ht=5ex,dp=1.125ex]{palette 
73       quaternary}%
74     \insertsectionnavigationhorizontal{\paperwidth}{}{\hskip0pt plus1filll}
75     \end{beamercolorbox}%
76   }
77   \fi
78 }
79
80 \makeatletter
81 \def\insertsectionnavigationhorizontal#1#2#3{%
82  \hbox to #1{{%
83    \def\slideentry##1##2##3##4##5##6{}%
84    #2\hskip.3cm%
85    \newdimen\tmp@parbox%
86    \setlength\tmp@parbox{#1}%
87    \addtolength\tmp@parbox{-.6cm}%
88    \parbox{\tmp@parbox}{\raggedleft%
89      \usebeamerfont{section in head/foot}\usebeamercolor[fg]{section in head/foot}%
90      \setbox\beamer@sectionbox=\hbox{}%
91      \ht\beamer@sectionbox=1.875ex%
92      \dp\beamer@sectionbox=0.75ex%
93      \hskip-1.875ex plus-1fill\dohead%
94      \box\beamer@sectionbox}\hfil\hskip.3cm%
95      #3}}}
96 \makeatother
97
98 %% Remove navigation 
99 \setbeamertemplate{navigation symbols}{}
100
101 \bibliography{bibliography/master-thesis-erlenkr-bibliography}
102
103 \begin{document}
104
105 \begin{frame}
106   \frametitle{\thetitle}
107 %  {\subtitle}
108 %  \vspace*{\baselineskip}
109
110   { \emph{Erlend Kristiansen, Universitetet i Oslo}}
111
112    {~~~~and}
113
114   { \emph{\underline{Volker Stolz, H\o gskolen i Bergen}}}
115   \vspace*{\baselineskip}
116 \end{frame}
117
118 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
119
120 \begin{frame}
121   \frametitle{Outline and Motivation}
122   \begin{itemize}
123   \item What are refactorings?
124   \item What are their problems?
125   \item How can we help?
126   \item Experiment and evaluation
127   \end{itemize}
128 \end{frame}
129 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
130
131 %\section{Definitions}
132
133 \begin{frame}
134   \frametitle{Refactoring, as defined in the literature}
135
136   \begin{quote}
137     \emph{Refactoring} (noun): a change made to the internal structure
138     of software to make it easier to understand and cheaper to modify without 
139     changing its observable behavior.~{\bf [Fowler]}
140   \end{quote}
141 \end{frame}
142
143 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
144 \begin{frame}
145   \frametitle{Why are they necessary?}
146   \vspace*{-2mm}
147   \includegraphics[scale=0.3]{../nik2014/abs-motivation.png}
148   
149   \vspace*{-2mm}
150   \begin{itemize}
151   \item anecdotal evidence from our own project
152   \item ``refactoring smells'' that should be avoided by programmers
153 %  \item (infrastructure developed here can be used for survey on repositories)
154   \end{itemize}
155 \end{frame}
156 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
157 \begin{frame}
158   \frametitle{An alternative definition of refactoring}
159
160   \begin{definition}
161     A \emph{refactoring} is a transformation
162     done to a program without altering its external behavior.
163   \end{definition}
164 \end{frame}
165
166 \begin{frame}
167   \frametitle{Primitive and composite refactorings}
168   \begin{definition}
169     A \emph{primitive refactoring} is a refactoring that cannot be expressed in 
170     terms of other refactorings.
171
172   \end{definition}
173
174   \begin{definition}
175     A \emph{composite refactoring} is a refactoring that can be expressed in 
176     terms of two or more other refactorings.
177   \end{definition}
178 \end{frame}
179
180 \section{Motivation}
181
182 \begin{frame}[fragile]
183 \def\charwidth{4.5pt}
184 \def\indent{2*\charwidth}
185 \def\rightColX{32*\charwidth*0}
186 \def\lineheight{\baselineskip}
187 \def\mintedtop{22.5pt}
188
189 \begin{minipage}[t]{0.45\textwidth}
190 \begin{tikzpicture}[overlay, yscale=-1]
191   \tikzstyle{overlaybox}=[fill=gray,opacity=0.2]
192   % Bad
193   \draw[overlaybox] (\indent,\mintedtop+\lineheight*3) rectangle 
194   +(16*\charwidth,2*\lineheight);
195 \end{tikzpicture}
196 \begin{minted}[linenos,samepage,frame=topline,label={Bad},framesep=\mintedframesep]{java}
197 class C {
198   A a; B b; X x;
199   void method() {
200     x.y.foo();
201     x.y.bar();
202   }
203 }
204 class X {
205   Y y;
206 }
207 class Y {
208   void foo(){/*...*/}
209   void bar(){/*...*/}
210 }
211 \end{minted}
212 \end{minipage}\hspace{0.1\textwidth}\pause\begin{minipage}[t]{0.45\textwidth}
213 \begin{tikzpicture}[overlay, yscale=-1]
214   \tikzstyle{overlaybox}=[fill=gray,opacity=0.2]
215   % Good
216   \draw[overlaybox] (\rightColX+\indent,\mintedtop+\lineheight*3) rectangle 
217   +(16*\charwidth,\lineheight);
218
219   \draw[overlaybox] (\rightColX,\mintedtop+\lineheight*8) rectangle 
220   +(19*\charwidth,4*\lineheight);
221
222   \draw[-latex,red] (-3,2.5) -- (-0.1,\mintedtop+\lineheight*9);
223   
224 \end{tikzpicture}
225 \begin{minted}[linenos,samepage,frame=topline,label={Good},framesep=\mintedframesep]{java}
226 class C {
227   A a; B b; X x;
228   void method() {
229     x.fooBar();
230   }
231 }
232 class X {
233   Y y;
234   void fooBar() {
235     y.foo();
236     y.bar();
237   }
238 }
239 class Y {
240   void foo(){/*...*/}
241   void bar(){/*...*/}
242 }
243   \end{minted}
244 \vfill
245 \end{minipage}
246 \end{frame}
247
248 \begin{frame}{What our refactoring is going to do for you}
249   \begin{itemize}
250     \item Get rid of long navigation paths.
251     \item Move operations closer to the data they manipulate.
252     \item Reduce coupling.
253     \item Increase maintainability.
254     \item []
255     \item Automatically!
256   
257   \end{itemize}
258
259 \end{frame}
260
261 \mysection{The primitive refactorings}
262
263 \begin{frame}[fragile]
264   \frametitle{The Extract Method refactoring}
265   Extract a fragment of code into a new method.
266
267 \def\charwidth{4.5pt}
268 \def\indent{2*\charwidth}
269 \def\rightColX{32*\charwidth*0}
270 \def\lineheight{\baselineskip}
271 \def\mintedtop{6.5pt}
272
273 \begin{minipage}[t]{0.45\textwidth}
274 \begin{tikzpicture}[overlay, yscale=-1]
275   \tikzstyle{overlaybox}=[fill=gray,opacity=0.2]
276   % Bad
277   \draw[overlaybox] (\indent,\mintedtop+\lineheight*3) rectangle 
278   +(16*\charwidth,2*\lineheight);
279 \end{tikzpicture}
280 \begin{minted}[linenos,samepage]{java}
281 class C {
282   A a; B b; X x;
283   void method() {
284     x.y.foo();
285     x.y.bar();
286   }
287 }
288 \end{minted}
289 \end{minipage}\hspace{0.1\textwidth}\pause\begin{minipage}[t]{0.45\textwidth}
290 \begin{tikzpicture}[overlay, yscale=-1]
291   \tikzstyle{overlaybox}=[fill=gray,opacity=0.2]
292   % Good
293   \draw[overlaybox] (\rightColX+\indent,\mintedtop+\lineheight*3) rectangle 
294   +(16*\charwidth,\lineheight);
295
296   \draw[overlaybox] (\rightColX,\mintedtop+\lineheight*5) rectangle 
297   +(19*\charwidth,4*\lineheight);
298
299   \draw[-latex,red] (-3,1.8) -- (-0.1,\mintedtop+\lineheight*6);
300   
301 \end{tikzpicture}
302 \begin{minted}[linenos,samepage]{java}
303 class C {
304   A a; B b; X x;
305   void method() {
306     fooBar();
307   }
308   void fooBar() {
309     x.y.foo();
310     x.y.bar();
311   }
312 }
313   \end{minted}
314 \vfill
315 \end{minipage}
316
317 \end{frame}
318
319
320 \begin{frame}[fragile]
321   \frametitle{The Move Method refactoring}
322   Move a method from one class to another.
323   
324 \def\charwidth{4.5pt}
325 \def\indent{2*\charwidth}
326 \def\rightColX{32*\charwidth*0}
327 \def\lineheight{\baselineskip}
328 \def\mintedtop{6.5pt}
329
330 \begin{minipage}[t]{0.45\textwidth}
331 \begin{tikzpicture}[overlay, yscale=-1]
332   \tikzstyle{overlaybox}=[fill=gray,opacity=0.2]
333   % Bad
334   \draw[overlaybox] (0,\mintedtop+\lineheight*5) rectangle 
335   +(19*\charwidth,4*\lineheight);
336 \end{tikzpicture}
337 \begin{minted}[linenos,samepage]{java}
338 class C {
339   A a; B b; X x;
340   void method() {
341     fooBar();
342   }
343   void fooBar() {
344     x.y.foo();
345     x.y.bar();
346   }
347 }
348 class X {
349   Y y;
350 }
351 \end{minted}
352 \end{minipage}\hspace{0.1\textwidth}\pause\begin{minipage}[t]{0.45\textwidth}
353 \begin{tikzpicture}[overlay, yscale=-1]
354   \tikzstyle{overlaybox}=[fill=gray,opacity=0.2]
355   % Good
356   \draw[overlaybox] (\rightColX+\indent,\mintedtop+\lineheight*3) rectangle 
357   +(16*\charwidth,\lineheight);
358
359   \draw[overlaybox] (\rightColX,\mintedtop+\lineheight*8) rectangle 
360   +(19*\charwidth,4*\lineheight);
361
362   \draw[-latex,red] (-2.8,2.9) -- (-0.1,\mintedtop+\lineheight*9.5);
363   
364 \end{tikzpicture}
365 \begin{minted}[linenos,samepage]{java}
366 class C {
367   A a; B b; X x;
368   void method() {
369     x.fooBar();
370   }
371 }
372 class X {
373   Y y;
374   void fooBar() {
375     y.foo();
376     y.bar();
377   }
378 }
379   \end{minted}
380 \vfill
381 \end{minipage}
382
383 \end{frame}
384
385
386 \mysection{The Extract and Move Method refactoring}
387
388 \begin{frame}[fragile]
389 \def\charwidth{4.5pt}
390 \def\indent{2*\charwidth}
391 \def\rightColX{32*\charwidth*0}
392 \def\lineheight{\baselineskip}
393 \def\mintedtop{22.5pt}
394
395 \begin{minipage}[t]{0.45\textwidth}
396 \begin{tikzpicture}[overlay, yscale=-1]
397   \tikzstyle{overlaybox}=[fill=gray,opacity=0.2]
398   % Before
399   \draw[overlaybox] (\indent,\mintedtop+\lineheight*3) rectangle 
400   +(16*\charwidth,2*\lineheight);
401 \end{tikzpicture}
402 \begin{minted}[linenos,samepage,frame=topline,label={Before},framesep=\mintedframesep]{java}
403 class C {
404   A a; B b; X x;
405   void method() {
406     x.y.foo();
407     x.y.bar();
408   }
409 }
410 class X {
411   Y y;
412 }
413 class Y {
414   void foo(){/*...*/}
415   void bar(){/*...*/}
416 }
417 \end{minted}
418 \end{minipage}\hspace{0.1\textwidth}\pause\begin{minipage}[t]{0.45\textwidth}
419 \begin{tikzpicture}[overlay, yscale=-1]
420   \tikzstyle{overlaybox}=[fill=gray,opacity=0.2]
421   % After
422   \draw[overlaybox] (\rightColX+\indent,\mintedtop+\lineheight*3) rectangle 
423   +(16*\charwidth,\lineheight);
424
425   \draw[overlaybox] (\rightColX,\mintedtop+\lineheight*8) rectangle 
426   +(19*\charwidth,4*\lineheight);
427
428   \draw[-latex,red] (-3,2.5) -- (-0.1,\mintedtop+\lineheight*9);
429   
430 \end{tikzpicture}
431 \begin{minted}[linenos,samepage,frame=topline,label={After},framesep=\mintedframesep]{java}
432 class C {
433   A a; B b; X x;
434   void method() {
435     x.fooBar();
436   }
437 }
438 class X {
439   Y y;
440   void fooBar() {
441     y.foo();
442     y.bar();
443   }
444 }
445 class Y {
446   void foo(){/*...*/}
447   void bar(){/*...*/}
448 }
449   \end{minted}
450 \vfill
451 \end{minipage}
452 \end{frame}
453
454 \begin{frame}
455   \def\secondlevelmark{\textbullet}
456   \begin{itemize}
457     \item Composed of \ExtractMethod and \MoveMethod.
458     \item Conceptually, one ``atomic'' operation.
459       \vspace{2.5pt}
460     \item Implemented as an Eclipse plugin.
461       \vspace{2pt}
462       \begin{itemize} \itemsep3pt
463         \item[\secondlevelmark] The primitive refactorings are supplied by the 
464           Eclipse JDT.
465         \item[\secondlevelmark] The composition work had to be done by us.
466         \item[\secondlevelmark] Not seamless (find the extracted method, move 
467           target etc.).
468
469       \end{itemize}
470
471   \end{itemize}
472
473 \end{frame}
474
475 %\mysection{Research questions}
476
477 \begin{frame}
478   Main research question:
479   \begin{quote}
480     Is it possible to automate the analysis and execution of the 
481     \ExtractAndMoveMethod refactoring, and do so for all of the code of a larger 
482     project?
483   \end{quote}
484   
485   Secondary questions:
486   \begin{itemize}
487     \item Can we do this efficiently?
488     \item Can we perform changes safely?
489     \item Can we improve the quality of source code?
490     \item How can the automation of the refactoring be helpful?
491   
492   \end{itemize}
493   
494 \end{frame}
495
496
497 \begin{frame}[fragile]{Automating the refactoring}
498   For any given method: We want to find the best candidate for the 
499   \ExtractAndMoveMethod refactoring, if any exist.
500
501   \begin{minipage}[b]{0.33\textwidth}
502   \hfill\vspace{0.5cm}
503   \end{minipage}\begin{minipage}[t]{0.5\textwidth}
504 \def\charwidth{4.5pt}
505 \def\indent{2*\charwidth}
506 \def\rightColX{32*\charwidth*0}
507 \def\lineheight{\baselineskip}
508 \def\mintedtop{6.5pt}
509
510 \begin{tikzpicture}[overlay, yscale=-1]
511   \tikzstyle{overlaybox}=[fill=gray,opacity=0.2]
512   \draw[overlaybox] (0,\mintedtop+\lineheight*3) rectangle 
513   +(16*\charwidth,2*\lineheight);
514
515   \node[draw opacity=0, text=red] at (20*\charwidth,\mintedtop+\lineheight*4) 
516   {\fontsize{40}{60}\selectfont ?};
517 \end{tikzpicture}
518 \begin{minted}[samepage]{java}
519 void method() {
520   statement_1;
521   statement_2;
522   statement_3;
523   statement_4;
524   statement_5;
525 }
526 \end{minted}
527   \end{minipage}
528
529 \end{frame}
530
531
532 \begin{frame}[fragile]
533 \begin{minipage}[t]{0.5\textwidth}
534 \def\charwidth{4.75pt}
535 \def\indent{2*\charwidth}
536 \def\lineheight{\baselineskip}
537 \def\mintedtop{5.8pt}
538
539 \begin{tikzpicture}[overlay, yscale=-1]
540   \tikzstyle{overlaybox}=[fill=gray,opacity=0.2]
541   \draw[overlaybox] (2*\indent,\mintedtop+12*\lineheight) rectangle 
542   +(14*\charwidth,2*\lineheight);
543
544   \draw[overlaybox] (9*\charwidth,\mintedtop+\lineheight) rectangle 
545   +(\charwidth,\lineheight);
546
547   \node[draw opacity=0, text=red] at (12.1*\indent,\mintedtop+12.9*\lineheight) 
548   {text selection};
549
550   \node[draw opacity=0, text=red] at (11.5*\indent,\mintedtop+4*\lineheight) 
551   {move target};
552
553   \draw[-latex,red] (11.5*\indent-5*\charwidth,\mintedtop+3.7*\lineheight) -- 
554   (10.2*\charwidth,\mintedtop+1.5*\lineheight);
555
556 \end{tikzpicture}
557 \begin{minted}[linenos,samepage]{java}
558 class C {
559   A a; B b; boolean bool;
560   void method(int val) {
561     if (bool) {
562       a.foo();
563       a = new A();
564       a.bar();
565     }
566     a.foo();
567     a.bar();
568     switch (val) {
569     case 1:
570       b.a.foo();
571       b.a.bar();
572       break;
573     default:
574       a.foo();
575     }
576   }
577 }
578 \end{minted}
579 \end{minipage}\begin{minipage}[t]{0.5\textwidth}
580   \pause
581   \vspace{1.2cm}
582   A \textbf{candidate} consists of a \emph{text selection} and a \emph{move 
583   target}.\\~\\
584
585   A \textbf{valid text selection} is a text selection that contains all of one 
586   or more consecutive program statements. It is the input to the \ExtractMethod 
587   refactoring.\\~\\
588
589   A \textbf{move target} is a variable (local or field), whose type is the 
590   destination class in the \MoveMethod refactoring.
591
592 \end{minipage}
593   
594 \end{frame}
595
596
597
598 \begin{frame}
599   \frametitle{Searching}
600   Usually, search-based refactoring is based on metrics.
601   \begin{itemize}
602     \item Refactor a lot.
603     \item Choose the best candidate based on measurements.
604   \end{itemize}
605
606   Our refactoring is based on heuristics.
607   \begin{itemize}
608     \item Up-front analysis.
609     \item A set of assumptions defining what is considered the best candidate.
610     \item No need to actually perform changes (before deciding).
611     \item Search through all valid selections to find the best candidate.
612   \end{itemize}
613
614 \end{frame}
615
616
617 \begin{frame}
618   \frametitle{Choosing a refactoring candidate}
619   \begin{itemize}
620     \item Search through all selections to find the possible candidates.
621     \item Find the best move target for all the candidates.
622     \item Choose the best among the possible candidates.
623     \item Based on the lengths of the navigation paths and the occurrence 
624       counts.
625   
626   \end{itemize}
627 \end{frame}
628
629 \begin{frame}{Case studies}
630   Case studies performed on the \code{org.eclipse.jdt.ui} and 
631   \code{no.uio.ifi.refaktor} projects. The resulting code was analyzed with 
632   SonarQube.
633   \vspace*{\baselineskip}
634
635   The Eclipse JDT UI project:
636   \begin{itemize}
637     \item Over 300,000 lines of code.
638     \item 2,552 methods out of 27,667 methods chosen to be refactored.
639     \item Approx. 100 minutes.
640   
641   \end{itemize}
642
643 \end{frame}
644
645 \begin{frame}
646   \frametitle{Quality Metrics}
647   
648 \begin{table}[ptb]
649   \caption[SonarQube analysis results for Eclipse JDT UI.]{Results for 
650     analyzing the Eclipse JDT UI project, before and after the refactoring, with 
651     \name{SonarQube} (bold numbers are better.)}
652
653   \centering\small
654 %  \begin{tabularx}{\textwidth}{@{}>{\bfseries}L{1.5}R{0.25}R{0.25}@{}}
655   \begin{tabularx}{\textwidth}{@{}>{}lrr@{}}
656     \toprule
657     \textbf{Number of issues for each rule} & \textbf{Before} & \textbf{After} \\
658     \midrule
659     Avoid too complex class & 81 & \textbf{79} \\
660     Classes should not be coupled to too many\\
661    \quad other classes (Single Responsibility Principle) & \textbf{1,098} & 1,199 \\
662     Control flow statements\\ \quad should not be nested too deeply & 1,375 & 
663     \textbf{1,285} \\
664     Methods should not be too complex & 1,518 & \textbf{1,452} \\
665     Methods should not have too many lines & 3,396 & \textbf{3,291} \\
666     NPath Complexity & 348 & \textbf{329} \\
667 %    Too many methods & \textbf{454} & 520 \\
668 %    \midrule
669     Complexity per function & 3.6 & \textbf{3.3} \\
670     % Total number of issues & 8,270 & \textbf{8,155} \\
671     % Per class & \textbf{29.5} & 30.4 \\
672     % Per file & \textbf{44.0} & 45.3 \\
673     % \midrule
674     % Total complexity & \textbf{84,765} & 87,257 \\
675     % \midrule
676     % \midrule
677     % \spancols{3}{Numbers of each type of entity analyzed} \\
678     % \midrule
679     % Files & 1,926 & 1,926 \\
680     % Classes & 2,875 & 2,875 \\
681     % Functions & 23,744 & 26,332 \\
682     % Accessors & 1,296 & 1,019 \\
683     % Statements & 162,768 & 165,145 \\
684     % Lines of code & 320,941 & 329,112 \\
685     % \midrule
686     % Technical debt (in days) & \textbf{1,003.4} & 1,032.7 \\
687     \bottomrule
688   \end{tabularx}
689 \end{table}
690
691 \end{frame}
692 \begin{frame}
693   \frametitle{The case studies are inconclusive}
694   \begin{itemize}
695     \item Measurements show some deterioration regarding coupling.
696     \item All improvement not measured, only strict coupling between classes.
697     \item Examples exist where coupling is improved.
698     \item More examples exist where dependencies are introduced.
699     \item[]
700     \item Needs more work!
701   \end{itemize}
702 \end{frame}
703
704 \section{Conclusions}
705
706 \begin{frame}{Conclusions and future work}
707   \begin{itemize}
708     \item Automation is possible.
709     \item Efficient enough for some kinds of use.
710     \item Difficult not to break source code.
711     \item Naive application introduces additional coupling.\\[2ex]
712     \item[] {\bf Future work:}
713   \item Better analysis (less crashes/broken output).
714   \item Improve heuristics to avoid introducing new dependencies.
715     \item Online suggestions?
716   \item Make refactoring safer.
717
718 \end{itemize}
719 \end{frame}
720
721 \end{document}