Suggest code improvements
2 listings
Prompts
Review code and get prioritized fixes
This prompt reviews a code snippet or diff the way a principal software engineer would. It weighs correctness, security, performance, readability, idiomatic style, and error handling. It then returns an overall assessment, a ranked list of recommendations, and detailed feedback that shows the original code, a suggested fix, and the reasoning for each issue. The output is Markdown and the prompt includes a worked example.