惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

WordPress大学
WordPress大学
A
About on SuperTechFans
小众软件
小众软件
Hugging Face - Blog
Hugging Face - Blog
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
博客园 - 叶小钗
博客园 - 聂微东
博客园 - Franky
Apple Machine Learning Research
Apple Machine Learning Research
罗磊的独立博客
量子位
博客园 - 三生石上(FineUI控件)
Recent Announcements
Recent Announcements
The GitHub Blog
The GitHub Blog
B
Blog RSS Feed
T
The Blog of Author Tim Ferriss
GbyAI
GbyAI
云风的 BLOG
云风的 BLOG
Last Week in AI
Last Week in AI
宝玉的分享
宝玉的分享
B
Blog
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
Stack Overflow Blog
Stack Overflow Blog
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC

DEV Community

Authentication Security Deep Dive: From Brute Force to Salted Hashing (With Java Examples) Why AI Systems Don’t Fail — They Drift Spilling beans for how i learn for exam😁"Reinforcement Learning Cheat Sheet" I Replaced Chrome with Safari for AI Browser Automation. Here's What Broke (and What Finally Worked) How Python Borrows Other People's Work The $40 Architecture: Processing 1 Billion API Requests with 99.99% Uptime Vibe Coding: A Workflow Guide (From Zero to SaaS) Most webhook security guides protect the wrong side. The scary part is delivery. Headless CMS for TanStack Start: Build a Blog with Cosmic EU Age Verification App "Hacked in 2 Minutes" — What Actually Happened Comfy Cloud’s delete function does not actually remove files Running AI Models on GPU Cloud Servers: A Beginner Guide Event-driven media intelligence with AWS Step Functions and Bedrock I scored 500 AI prompts across 8 quality dimensions — here's what broke How to Call Google Gemini API from Next.js (Free Tier, No Backend Needed) The Portal Protocol: Reclaiming Human Connection in the Age of AI How to Fix Your Team's Scattered Knowledge Problem With a Self-Hosted Forum Intro to tc Cloud Functors: A Graph-First Mental Model for the Modern Cloud Designing Multi-Tenant Backends With Both Ownership and Team Access I Built a Neumorphic CSS Library with 77+ Components — Here's What I Learned PostgreSQL Performance Optimization: Why Connection Pooling Is Critical at Scale Cómo construí un SaaS multi-rubro para gestionar expensas en Argentina con FastAPI + Vue 3 🚀 I Built an Ethical Hacking Scanner Tool – Open Source Project I Replaced /usage and /context in Claude Code With a Single Statusline A Pythonic Way to Handle Emails (IMAP/SMTP) with Auto-Discovery and AI-Ready Design I Collected 8.9 Million Polymarket Price Points — Here's What I Found About How Markets Really Move EcoTrack AI — Carbon Footprint Tracker & Dashboard Everyone's Using AI. No One Agrees How. 5 self-hosted ebook managers worth trying in 2026 Building Your First AI Agent with LangChain: From Chatbot to Autonomous Assistant
Mapping the Delphi Bible to CrabPascal | Mapeando a Bíbli...
CrabPascal · 2026-06-04 · via DEV Community

Bilingual post · Post bilíngue

Jump to: English · Português


English {#english}

Mapping the Delphi Bible to CrabPascal

Series — Part 2: Previous: Learn Compilers Using CrabPascal (055-compiler-course-with-crabpascal). Analysis doc: resources/analise-biblia-delphi-v1-7. Compatibility map: roadmap/review-360.

Every Delphi team has a shelf weight: reference material spanning decades. CrabPascal's analise-biblia-delphi-v1-7 document maps one such source — BibliaDelphi8.md (75,000+ lines) — against compiler capabilities. This post explains how we use "Bible-scale" references without drowning in scope, and how you can do the same for your migration.

Why map a Delphi reference to CrabPascal?

Compatibility is not a vibe — it is a checklist. The 360° review (roadmap/review-360) lists pipeline gaps; the Bible analysis adds frequency-weighted language features:

  • What 90% of Delphi code uses (case, repeat, with)
  • What blocks enterprise units (generics edge cases, RTTI)
  • What already shipped in v1.5.x–v2.22.0

The analysis dated October 2025 remains a template: pick a chapter, grep CrabPascal, assign sprint priority.

Already implemented (baseline)

When the analysis was written, these were confirmed:

Feature CrabPascal status
if/for/while Core from v1.0
Classes, inheritance, virtual/override v1.5+
try/except/finally v1.4+
Properties, Self, Result, Exit v1.4+
Preprocessor {$IFDEF} v1.5.2
as / is operators v1.5.3
14 numeric types including Double v1.5.1

Sprints 1–14 added namespaces, generics collections, Unicode groundwork, parser hardening, and IOUtils — closing many Bible gaps post-analysis.

High-priority gaps identified

The analysis flagged essentials many codebases use daily:

CASE OF

case Grade of
  'A': WriteLn('Excellent');
  'B'..' 'D': WriteLn('Pass');
else
  WriteLn('Fail');
end;

Enter fullscreen mode Exit fullscreen mode

Importance: Very high. Difficulty: Low (similar to if chains). Parser sprint candidate.

REPEAT-UNTIL

Post-check loop common in legacy code. Similar to while with inverted test — low implementation cost, high adoption impact.

WITH statement

with Customer do
begin
  Name := 'Acme';
  Active := True;
end;

Enter fullscreen mode Exit fullscreen mode

Still partially runtime-only in C codegen (TD-CODEGEN-004). run path priority for teaching material.

SET types and advanced constructs

Lower frequency in modern code but appear in older units — backlog after P0 parity items.

How the Bible analysis feeds sprints

Each candidate feature gets:

  • Importance stars — derived from handbook usage patterns
  • Difficulty estimate — parser vs runtime vs codegen
  • Time box — prevents eternal research threads

Squad rule from roadmap/squad: if it does not help a real Delphi project compile better, it waits. Bible mapping filters noise.

Practical workflow for your unit

Migrating LegacyModule.pas?

  1. Open roadmap/review-360 — check Priority 0/1 blockers
  2. Cross-reference constructs in your unit against analise-biblia-delphi-v1-7 tables
  3. Run:
crab-pascal check LegacyModule.pas

Enter fullscreen mode Exit fullscreen mode

  1. For each error, classify: parser, RTL shim, runtime, or codegen parity
  2. File minimal fixture — one construct per file

Resources beyond the Bible

Mintlify resources/readme lists handbooks and external PDFs (Object Pascal Handbook Sydney). Use them the same way: syntax validation, semantic rules, missing builtin discovery.

Honest limits

CrabPascal will not implement every Delphi feature at once. The Bible map prioritizes language surface; VCL/FMX UI is out of scope. Horse REST demos replace GUI for killer-app narratives.

Native codegen still refuses unsupported constructs honestly (exceptions in build-exe until real lowering exists).

Takeaway

Reference tomes are not roadmaps alone — they are input to a prioritized backlog. The BibliaDelphi analysis shows how CrabPascal turns 75k lines into sprint-sized bullets tied to real developer pain. Use the same method on your codebase before blaming "the compiler."

Next: The v2.8 Hotfix Story (057-v28-hotfix-story).


Português {#portugus}

Mapeando a Bíblia Delphi no CrabPascal

Série — Parte 2: Anterior: Aprenda compiladores com CrabPascal (055-compiler-course-with-crabpascal). Análise: resources/analise-biblia-delphi-v1-7. Mapa de compatibilidade: roadmap/review-360.

Todo time Delphi tem peso de prateleira: material de referência de décadas. O documento analise-biblia-delphi-v1-7 do CrabPascal mapeia uma dessas fontes — BibliaDelphi8.md (75.000+ linhas) — contra capacidades do compilador. Este post explica como usamos referências "escala Bíblia" sem afogar em escopo, e como você pode fazer o mesmo na migração.

Por que mapear referência Delphi no CrabPascal?

Compatibilidade não é feeling — é checklist. O review 360° (roadmap/review-360) lista gaps do pipeline; a análise da Bíblia adiciona features de linguagem ponderadas por frequência:

  • O que 90% do código Delphi usa (case, repeat, with)
  • O que bloqueia units enterprise (edge cases de generics, RTTI)
  • O que já shipou em v1.5.x–v2.22.0

A análise datada de outubro/2025 permanece template: escolha capítulo, grep CrabPascal, assign prioridade de sprint.

Já implementado (baseline)

Quando a análise foi escrita, estes estavam confirmados:

Feature Status CrabPascal
if/for/while Core desde v1.0
Classes, herança, virtual/override v1.5+
try/except/finally v1.4+
Properties, Self, Result, Exit v1.4+
Preprocessor {$IFDEF} v1.5.2
Operadores as / is v1.5.3
14 tipos numéricos incluindo Double v1.5.1

Sprints 1–14 adicionaram namespaces, generics collections, base Unicode, parser hardening e IOUtils — fechando muitos gaps pós-análise.

Gaps de alta prioridade identificados

A análise sinalizou essenciais que codebases usam diariamente:

CASE OF

case Nota of
  'A': WriteLn('Excelente');
  'B'..'D': WriteLn('Aprovado');
else
  WriteLn('Reprovado');
end;

Enter fullscreen mode Exit fullscreen mode

Importância: Muito alta. Dificuldade: Baixa (similar a cadeias if). Candidato a sprint de parser.

REPEAT-UNTIL

Loop pós-condição comum em código legado. Similar a while com teste invertido — baixo custo, alto impacto de adoção.

WITH statement

with Cliente do
begin
  Nome := 'Acme';
  Ativo := True;
end;

Enter fullscreen mode Exit fullscreen mode

Ainda parcialmente runtime-only no codegen C (TD-CODEGEN-004). Prioridade do caminho run para material didático.

SET types e construtos avançados

Menor frequência em código moderno, mas aparecem em units antigas — backlog após itens P0 de paridade.

Como a análise da Bíblia alimenta sprints

Cada feature candidata recebe:

  • Estrelas de importância — derivadas de padrões de uso no handbook
  • Estimativa de dificuldade — parser vs runtime vs codegen
  • Time box — evita threads eternas de pesquisa

Regra da squad em roadmap/squad: se não ajuda projeto Delphi real a compilar melhor, espera. Mapeamento da Bíblia filtra ruído.

Workflow prático para sua unit

Migrando ModuloLegado.pas?

  1. Abra roadmap/review-360 — cheque blockers Prioridade 0/1
  2. Cruze construtos da unit com tabelas de analise-biblia-delphi-v1-7
  3. Rode:
crab-pascal check ModuloLegado.pas

Enter fullscreen mode Exit fullscreen mode

  1. Para cada erro, classifique: parser, shim RTL, runtime ou paridade codegen
  2. Arquivo fixture mínimo — um construto por arquivo

Recursos além da Bíblia

O resources/readme Mintlify lista handbooks e PDFs externos (Object Pascal Handbook Sydney). Use da mesma forma: validação de sintaxe, regras semânticas, descoberta de builtin faltante.

Limites honestos

CrabPascal não implementará toda feature Delphi de uma vez. O mapa da Bíblia prioriza surface de linguagem; UI VCL/FMX está fora de escopo. Demos Horse REST substituem GUI para narrativas killer-app.

Codegen nativo ainda recusa construtos não suportados honestamente (exceptions em build-exe até lowering real existir).

Conclusão

Tomos de referência não são roadmap sozinhos — são input para backlog priorizado. A análise BibliaDelphi mostra como CrabPascal transforma 75k linhas em bullets tamanho sprint ligados a dor real de desenvolvedor. Use o mesmo método no seu codebase antes de culpar "o compilador."

Próximo: História dos hotfixes v2.8 (057-v28-hotfix-story).


Published on dev.to/@crabpascal · Código em CrabPascal