Skip to content

Latest commit

 

History

History
44 lines (25 loc) · 1.34 KB

File metadata and controls

44 lines (25 loc) · 1.34 KB

AST from custom linters to writing transpilers

This repository contains materials for my speech at Pycon PL 2025.

You are free to use it as reference for your studies.

About speech

Title: AST from custom linters to writing transpilers

Description: In this speech I explained shortly what are Abstract Syntax Trees and how you can use them to leverage you code.

Date: 30.03.2025

Difficulty: intermediate

Content

In this repository you can find following:

  • presentation.pptx PowerPoint presentation used in the speech
  • 01_linter directory containing 2 examples of writing linters:
    • raw script with writing NodeVisitor using built-in ast module
    • flake8 local-plugin
  • 02_code_generation directory containing examples of code generation using ast
  • schema.json file used in code generation example
  • code_with_problems.py file used in linter examples

Additional info

Third example about writing transpilers can be found in this project: salazaar

License

License: CC BY-NC-ND 4.0

This presentation is licensed under a Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International License.