Date of Award

2025

Document Type

Open Access Master's Thesis

Degree Name

Master of Science in Computer Science (MS)

Administrative Home Department

Department of Computer Science

Advisor 1

Leo C. Ureel II

Committee Member 1

Laura Brown

Committee Member 2

Michelle Jarvie-Eggart

Committee Member 3

Jon Sticklen

Abstract

Finding antipatterns in student code is a difficult task that is useful for helping beginner programmers. Antipatterns are common mistakes that students make while writing code. Code critiquers are tools that find antipatterns and provide rich, immediate feedback to students, even when professors aren’t available. WebTA is a code critiquer that finds antipatterns using regular expressions (regex), error messages, and language-specific abstract syntax trees (ASTs). Each of these tools has obstacles to antipattern searching that are difficult to overcome. Regex is without context, limiting the patterns it can recognize. Additionally, even experienced users have difficulty reading and debugging regex. Error messages and language-specific abstract syntax trees must be implemented for each language. Error messages are also restricted to finding syntax and other error-related antipatterns. Finally, language-specific abstract syntax trees require rebuilding and redeploying in the current design of WebTA for each new or modified antipattern query. This thesis presents two tools and a collection of antipatterns to solve these issues. The first tool, C-Slam, is a multi-language code critic that uses a combination of AST searching and Python scripts to easily find antipatterns. The second, Universal Abstract Syntax Trees (UASTs), creates a rule-based system for converting ASTs into UASTs. This makes antipatterns that are identical between two languages need only one query to be matched. Finally, this collection of antipatterns is used to show the usefulness of UASTs and provide a starting point for the implementation of future code critiquers.

Creative Commons License

Creative Commons Attribution-Noncommercial 4.0 License
This work is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 4.0 License.

Share

COinS