Blogs (1) >>
ICSE 2019
Sat 25 - Fri 31 May 2019 Montreal, QC, Canada
Wed 29 May 2019 16:00 - 16:20 at Place du Canada - Studying Developers Chair(s): Thomas Fritz

Best practices for developers, as encoded in recent programming language designs, recommend the use of immutability whenever practical. However, there is a lack of empirical evidence about the uptake of this advice. Our goal is to understand the usage of immutability by C++ developers in practice. This work investigates how C++ developers use immutability by analyzing their use of the C++ immutability qualifier, const. In particular, we answer the following broad questions about const usage: 1) do developers actually write non-trivial (more than 3 methods) immutable classes and immutable methods? 2) do developers label their immutable classes and methods?

We analyzed 7 medium-to-large open source projects and collected two sources of empirical data: 1) const annotations by developers, indicating an intent to write immutable code; and 2) the results of a simple static analysis which identified easily const-able methods—those that clearly did not mutate state. On average, we found that about 12% of non-trivial classes are immutable. We found the vast majority of classes do benefit from immutability labels on methods: surprisingly, developers const-annotate 46% of methods, and we estimate that at least 51% of methods could be const-annotated. Furthermore, developers missed immutability labels on at least 6% of unannotated methods. We provide an in-depth discussion on how developers write const and the results of our analyses.

Wed 29 May
Times are displayed in time zone: Eastern Time (US & Canada) change

16:00 - 18:00: Studying DevelopersPapers / Technical Track / New Ideas and Emerging Results / Journal-First Papers at Place du Canada
Chair(s): Thomas FritzUniversity of Zurich, University of British Columbia
16:00 - 16:20
Talk
Technical Track
Jon EyolfsonUniversity of Waterloo, Patrick LamUniversity of Waterloo
16:20 - 16:30
Talk
Journal-First Papers
Davide FucciUniversity of Hamburg, Giuseppe ScannielloUniversity of Basilicata, Simone RomanoUniversity of Basilicata, Natalia JuristoUniversidad Politecnica de Madrid
16:30 - 16:50
Talk
Technical Track
Souti ChattopadhyayGraduate Student, Nicholas NelsonOregon State University, Yenifer Ramirez GonzalezOregon State University, Annel Amelia LeonOregon State University, Rahul PanditaPhase Change Software, Anita SarmaOregon State University
16:50 - 17:10
Talk
Technical Track
Nahla Abid, Bonita SharifUniversity of Nebraska-Lincoln, USA, Natalia DraganKent State University, Hend AlrasheedKent State University, Jonathan MaleticKent State University
17:10 - 17:30
Talk
Technical Track
Yu HuangUniversity of Michigan, Xinyu LiuUniversity of Michigan, Ryan KruegerUniversity of Michigan, Tyler SantanderUniversity of California at Santa Barbara, Xiaosu HuUniversity of Michigan, Kevin LeachUniversity of Michigan, Westley WeimerUniversity of Michigan
Pre-print
17:30 - 17:40
Talk
New Ideas and Emerging Results
Ricardo CouceiroUniversity of Coimbra, Gonçalo DuarteUniversity of Coimbra, João DurãesCISUC, Polytechnic Institute of Coimbra, João CastelhanoICNAS, University of Coimbra, Catarina DuarteICNAS, University of Coimbra, Cesar TeixeiraUniversity of Coimbra, Miguel Castelo BrancoICNAS/CIBIT, University of Coimbra, Paulo CarvalhoUniversity of Coimbra, Henrique MadeiraUniversity of Coimbra
17:40 - 18:00
Talk
Papers