From 4e965c7d9a66d6a72b24c7b319c10d8006f2026e Mon Sep 17 00:00:00 2001 From: Mark Powers Date: Tue, 19 Jul 2022 21:12:41 -0500 Subject: Initial Commit --- content/blog/refactoring_via_synthesis.md | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 content/blog/refactoring_via_synthesis.md (limited to 'content/blog/refactoring_via_synthesis.md') diff --git a/content/blog/refactoring_via_synthesis.md b/content/blog/refactoring_via_synthesis.md new file mode 100644 index 0000000..3c1bd72 --- /dev/null +++ b/content/blog/refactoring_via_synthesis.md @@ -0,0 +1,20 @@ +--- +title: "Refactoring via Synthesis" +date: 2020-03-12T20:44:48-05:00 +--- +I finally have released my final project from last semester for my Programming Verification and Synthesis course. I made a frontend for it so it can be used as a web app. (Please be kind with any requests, as it can take a while per each one). The idea is to take a segment of code, and replace it with a shorter one, along with some method declarations. + + +*How to use*: + +The first box is (restricted) java code. Keep to one statement per line, and don't use the compound assignment operators (+=, etc). Avoid for loops and instead use while loops. All variables must be int types, and do not include declarations within the code segment. + +The second box is the set of variables (comma seperated) to check for equality on. After refactoring, the new code will ensure these variables are the same as in the original. By contrast, not all variables may be important after the code body, and so their equality does not matter. + +The third box is the set of java classes that may be used (comma seperated). Works best at calling static methods. There is no way to use a custom class as of now, so you are limited to the standard Java API. + +The fourth box is any delcarations to make for variables. These are variables that should not have values prior to the code segment. + +After clicked refactor, a new body of code will be generated that is equal (ideally) to the original code. + +Check it out here: https://refactoring.marks.kitchen/ -- cgit v1.2.3