Code Smells in Functional Programming: Initial Findings from a Grey Literature Review on Clojure
Resumo
Code smells are widely used indicators of poor code quality, revealing structural problems and areas where improvement can be made. Although extensively studied in object-oriented languages, functional programming languages remain comparatively underexplored in literature. This paper presents early results from a grey literature investigation of code smells in Clojure, a modern functional programming language that runs on the Java Virtual Machine (JVM) and is widely adopted in open source and industrial systems. Inspired by prior work on Elixir, we manually inspected developer discussions retrieved through Google search, extracted quality concerns discussed by developers, and had 44 practitioners evaluate the relevance of non-traditional smell candidates. As preliminary results, we cataloged 26 code smells, including 12 Clojure-specific, 9 functional-style, and 5 traditional Fowler smells. We also analyzed tool support and observed a significant gap, as existing Clojure linters cover only 2 of these 26 smells. These findings provide an initial characterization of how Clojure developers discuss code smells, a preliminary set of smell-like problems specific to this ecosystem, and an early assessment of tool support for their detection.
Palavras-chave:
Code Smells, Clojure, Grey Literature
Referências
Walber Araújo, José Truta, Rafael Serey, Thiago Laurentino, and João Brunet. 2025. clj-smells-catalog: Catalog of Clojure-related code smells. [link]. GitHub repository. Accessed: May 20, 2026.
Walber Araújo, José Truta, Lucas Vegi, Marco Tulio Valente, and João Brunet. 2026. Replication Package: Code Smells in the Clojure Ecosystem. DOI: 10.5281/zenodo.20293947
Phil Bagwell. 2001. Ideal Hash Trees. Technical Report. EPFL. Available at: [link].
Christopher M. Brown and Simon Thompson. 2010. Clone Detection and Elimination for Haskell. In ACM SIGPLANWorkshop on Partial Evaluation and Program Manipulation (PEPM). 111–120. DOI: 10.1145/1706356.1706378
Suelen Goularte Carvalho, Maurício Aniche, Júlio Veríssimo, Rafael S. Durelli, and Marco Aurélio Gerosa. 2019. An empirical catalog of code smells for the presentation layer of Android apps. Empirical Software Engineering 24 (2019), 3546–3586. DOI: 10.1007/s10664-019-09768-9
clj-kondo Contributors. 2026. clj-kondo. [link]. Accessed: 2026-05-14.
clojure-lsp contributors. 2024. Clojure LSP. [link]. Accessed: 2026-05-14.
Clojure.org. 2026. The Reader. [link] Accessed: 2026-05-18.
Jonathan Cowie. 2005. Detecting bad smells in Haskell. Technical Report. University of Kent, UK.
Eastwood Contributors. 2024. Eastwood: Clojure Linter. [link]. Accessed: 2026-05-14.
Viktória Fördős and Melinda Tóth. 2016. Identifying Code Clones with RefactorErl. Acta Cybernetica 22, 3 (2016), 553–571. DOI: 10.14232/actacyb.22.3.2016.1
Martin Fowler, Kent Beck, John Brant, William Opdyke, and Don Roberts. 1999. Refactoring: Improving the Design of Existing Code (1st ed.). Addison-Wesley, Boston, MA, USA.
Vahid Garousi, Michael Felderer, and Mika V. Mäntylä. 2019. Guidelines for including grey literature and conducting multivocal literature reviews in software engineering. Information and Software Technology 106 (2019), 101–121. DOI: 10.1016/j.infsof.2018.09.006
Tim Harris, Simon Marlow, Simon Peyton-Jones, and Maurice Herlihy. 2005. Composable memory transactions. In Proceedings of the Tenth ACM SIGPLAN Symposium on Principles and Practice of Parallel Programming (Chicago, IL, USA) (PPoPP ’05). Association for Computing Machinery, New York, NY, USA, 48–60. DOI: 10.1145/1065944.1065952
Rich Hickey. 2008. The Clojure programming language. In Proceedings of the 2008 Symposium on Dynamic Languages (Paphos, Cyprus) (DLS ’08). Association for Computing Machinery, New York, NY, USA, Article 1, 1 pages. DOI: 10.1145/1408681.1408682
Rich Hickey. 2026. Clojure Programming Language. [link]. Accessed: 2026-05-14.
joker Contributors. 2026. Joker: Small Clojure Interpreter, Linter, and Formatter. [link]. Accessed: 2026-05-19.
Frederick P. Brooks Jr. 1982. The Mythical Man-Month: Essays on Software Engineering. Addison-Wesley, Reading, Massachusetts.
Kibit Contributors. 2024. Kibit. [link]. Accessed: 2026-05-14.
Thiago Laurentino, Rafael Serey, Walber Araújo, Natália Rodrigues, and João Brunet. 2026. ARIT: A Tool for Detecting Code Smells in Clojure Programs. In Proceedings of the XVII Brazilian Conference on Software: Theory and Practice (CBSoft), Tool Session. Sociedade Brasileira de Computação (SBC), São Paulo, Brazil. To appear.
Huiqing Li and Simon Thompson. 2009. Clone Detection and Removal for Erlang/OTP within a Refactoring Environment. In ACM SIGPLAN Workshop on Partial Evaluation and Program Manipulation (PEPM). 169–178. DOI: 10.1145/1480945.1480971
Huiqing Li and Simon Thompson. 2010. Refactoring Support for Modularity Maintenance in Erlang. In 10th IEEE Working Conference on Source Code Analysis and Manipulation (SCAM). 157–166. DOI: 10.1109/SCAM.2010.17
T. Mens and T. Tourwe. 2004. A survey of software refactoring. IEEE Transactions on Software Engineering 30, 2 (2004), 126–139. DOI: 10.1109/TSE.2004.1265817
PMD Developers. 2024. PMD: Source Code Analyzer for Java, JavaScript, Salesforce, and More. [link]. Accessed: 2026-05-14.
Pablo Lamela Seijas and Simon Thompson. 2016. Identifying and Introducing Interfaces and Callbacks Using Wrangler. In 28th Symposium on the Implementation and Application of Functional Programming Languages (IFL). 1–13. DOI: 10.1145/3064899.3064909
SonarSource. 2024. SonarQube: Continuous Inspection of Code Quality. [link]. Accessed: 2026-05-14.
Simon Thompson, Huiqing Li, and Andreas Schumacher. 2017. The pragmatics of clone detection and elimination. The Art, Science, and Engineering of Programming 1, 2 (2017), 1–34.
Lucas Vegi and Marco Valente. 2025. Code Smells and Refactorings for Elixir. In Anais do XXXVIII Concurso de Teses e Dissertações (Maceió/AL). SBC, Porto Alegre, RS, Brasil, 94–103. DOI: 10.5753/ctd.2025.9280
Lucas Francisco da Matta Vegi and Marco Tulio Valente. 2022. Code smells in Elixir: early results from a grey literature review. In Proceedings of the 30th IEEE/ACM International Conference on Program Comprehension (ICPC ’22). ACM, 580–584. DOI: 10.1145/3524610.3527881
Lucas Francisco Matta Vegi and Marco Tulio Valente. 2023. Understanding code smells in Elixir functional language. Empirical Software Engineering 28, 102 (2023), 1–32. DOI: 10.1007/s10664-023-10343-6
Patrick Henry Winston and Berthold K Horn. 1986. Lisp. (1986).
Haiyin Zhang, Luís Cruz, and Arie Van Deursen. 2022. Code Smells for Machine Learning Applications. In Proceedings - 1st International Conference on AI Engineering - Software Engineering for AI, CAIN 2022. IEEE/ACM, Pittsburgh, PA, USA, 217–228. DOI: 10.1145/3522664.3528620
Walber Araújo, José Truta, Lucas Vegi, Marco Tulio Valente, and João Brunet. 2026. Replication Package: Code Smells in the Clojure Ecosystem. DOI: 10.5281/zenodo.20293947
Phil Bagwell. 2001. Ideal Hash Trees. Technical Report. EPFL. Available at: [link].
Christopher M. Brown and Simon Thompson. 2010. Clone Detection and Elimination for Haskell. In ACM SIGPLANWorkshop on Partial Evaluation and Program Manipulation (PEPM). 111–120. DOI: 10.1145/1706356.1706378
Suelen Goularte Carvalho, Maurício Aniche, Júlio Veríssimo, Rafael S. Durelli, and Marco Aurélio Gerosa. 2019. An empirical catalog of code smells for the presentation layer of Android apps. Empirical Software Engineering 24 (2019), 3546–3586. DOI: 10.1007/s10664-019-09768-9
clj-kondo Contributors. 2026. clj-kondo. [link]. Accessed: 2026-05-14.
clojure-lsp contributors. 2024. Clojure LSP. [link]. Accessed: 2026-05-14.
Clojure.org. 2026. The Reader. [link] Accessed: 2026-05-18.
Jonathan Cowie. 2005. Detecting bad smells in Haskell. Technical Report. University of Kent, UK.
Eastwood Contributors. 2024. Eastwood: Clojure Linter. [link]. Accessed: 2026-05-14.
Viktória Fördős and Melinda Tóth. 2016. Identifying Code Clones with RefactorErl. Acta Cybernetica 22, 3 (2016), 553–571. DOI: 10.14232/actacyb.22.3.2016.1
Martin Fowler, Kent Beck, John Brant, William Opdyke, and Don Roberts. 1999. Refactoring: Improving the Design of Existing Code (1st ed.). Addison-Wesley, Boston, MA, USA.
Vahid Garousi, Michael Felderer, and Mika V. Mäntylä. 2019. Guidelines for including grey literature and conducting multivocal literature reviews in software engineering. Information and Software Technology 106 (2019), 101–121. DOI: 10.1016/j.infsof.2018.09.006
Tim Harris, Simon Marlow, Simon Peyton-Jones, and Maurice Herlihy. 2005. Composable memory transactions. In Proceedings of the Tenth ACM SIGPLAN Symposium on Principles and Practice of Parallel Programming (Chicago, IL, USA) (PPoPP ’05). Association for Computing Machinery, New York, NY, USA, 48–60. DOI: 10.1145/1065944.1065952
Rich Hickey. 2008. The Clojure programming language. In Proceedings of the 2008 Symposium on Dynamic Languages (Paphos, Cyprus) (DLS ’08). Association for Computing Machinery, New York, NY, USA, Article 1, 1 pages. DOI: 10.1145/1408681.1408682
Rich Hickey. 2026. Clojure Programming Language. [link]. Accessed: 2026-05-14.
joker Contributors. 2026. Joker: Small Clojure Interpreter, Linter, and Formatter. [link]. Accessed: 2026-05-19.
Frederick P. Brooks Jr. 1982. The Mythical Man-Month: Essays on Software Engineering. Addison-Wesley, Reading, Massachusetts.
Kibit Contributors. 2024. Kibit. [link]. Accessed: 2026-05-14.
Thiago Laurentino, Rafael Serey, Walber Araújo, Natália Rodrigues, and João Brunet. 2026. ARIT: A Tool for Detecting Code Smells in Clojure Programs. In Proceedings of the XVII Brazilian Conference on Software: Theory and Practice (CBSoft), Tool Session. Sociedade Brasileira de Computação (SBC), São Paulo, Brazil. To appear.
Huiqing Li and Simon Thompson. 2009. Clone Detection and Removal for Erlang/OTP within a Refactoring Environment. In ACM SIGPLAN Workshop on Partial Evaluation and Program Manipulation (PEPM). 169–178. DOI: 10.1145/1480945.1480971
Huiqing Li and Simon Thompson. 2010. Refactoring Support for Modularity Maintenance in Erlang. In 10th IEEE Working Conference on Source Code Analysis and Manipulation (SCAM). 157–166. DOI: 10.1109/SCAM.2010.17
T. Mens and T. Tourwe. 2004. A survey of software refactoring. IEEE Transactions on Software Engineering 30, 2 (2004), 126–139. DOI: 10.1109/TSE.2004.1265817
PMD Developers. 2024. PMD: Source Code Analyzer for Java, JavaScript, Salesforce, and More. [link]. Accessed: 2026-05-14.
Pablo Lamela Seijas and Simon Thompson. 2016. Identifying and Introducing Interfaces and Callbacks Using Wrangler. In 28th Symposium on the Implementation and Application of Functional Programming Languages (IFL). 1–13. DOI: 10.1145/3064899.3064909
SonarSource. 2024. SonarQube: Continuous Inspection of Code Quality. [link]. Accessed: 2026-05-14.
Simon Thompson, Huiqing Li, and Andreas Schumacher. 2017. The pragmatics of clone detection and elimination. The Art, Science, and Engineering of Programming 1, 2 (2017), 1–34.
Lucas Vegi and Marco Valente. 2025. Code Smells and Refactorings for Elixir. In Anais do XXXVIII Concurso de Teses e Dissertações (Maceió/AL). SBC, Porto Alegre, RS, Brasil, 94–103. DOI: 10.5753/ctd.2025.9280
Lucas Francisco da Matta Vegi and Marco Tulio Valente. 2022. Code smells in Elixir: early results from a grey literature review. In Proceedings of the 30th IEEE/ACM International Conference on Program Comprehension (ICPC ’22). ACM, 580–584. DOI: 10.1145/3524610.3527881
Lucas Francisco Matta Vegi and Marco Tulio Valente. 2023. Understanding code smells in Elixir functional language. Empirical Software Engineering 28, 102 (2023), 1–32. DOI: 10.1007/s10664-023-10343-6
Patrick Henry Winston and Berthold K Horn. 1986. Lisp. (1986).
Haiyin Zhang, Luís Cruz, and Arie Van Deursen. 2022. Code Smells for Machine Learning Applications. In Proceedings - 1st International Conference on AI Engineering - Software Engineering for AI, CAIN 2022. IEEE/ACM, Pittsburgh, PA, USA, 217–228. DOI: 10.1145/3522664.3528620
Publicado
08/09/2026
Como Citar
ARAÚJO, Walber; TRUTA, José; VEGI, Lucas; VALENTE, Marco Tulio; BRUNET, João.
Code Smells in Functional Programming: Initial Findings from a Grey Literature Review on Clojure. In: WORKSHOP EM ENGENHARIA DE SOFTWARE PARA PROGRAMAÇÃO FUNCIONAL (SE4FP), 2. , 2026, São Paulo/SP.
Anais [...].
Porto Alegre: Sociedade Brasileira de Computação,
2026
.
p. 13-18.
DOI: https://doi.org/10.5753/se4fp.2026.32267.