开发者
How I Built My Own Programming Language from Scratch
I Built a Programming Language Called Zen Building a programming language had been something I wanted to do for a long time. What I didn't realize when I started was how much work exists beyond parsing a few tokens and generating some code. A language is not just a parser or a compiler backend. It is tooling, developer experience, documentation, installation, error handling, runtime support, and countless design decisions. After multiple attempts and many lessons learned, I'm excited to share Zen. Why a Third Attempt? Zen is not the first language project I started. My first attempts taught me a lot, but they never reached a stage where I felt comfortable sharing them publicly. The architecture was incomplete, important components were missing, and the overall developer experience wasn't where I wanted it to be. Instead of abandoning the idea, I kept iterating. Each attempt helped me better understand: Compiler architecture Language design LLVM Runtime integration Tooling and usability Error handling Project structure Zen is the result of those lessons. What Is Zen? Zen is a programming language with its own compiler pipeline and LLVM-based backend. The goal was not just to generate code, but to create a complete language ecosystem that developers can actually install and use. Zen currently includes: Lexer Parser AST generation LLVM IR generation Native executable generation through LLVM Runtime integration Standard library integration Command-line tooling Installation system Documentation website Compiler Pipeline The compilation process follows a traditional compiler architecture: Source Code ↓ Lexer ↓ Parser ↓ AST ↓ LLVM IR Generation ↓ LLVM Optimization ↓ Object Files ↓ Native Executable LLVM handles optimization and machine code generation, allowing Zen to produce native binaries. Command Line Interface Zen provides several commands for development and inspection: zen run zen build zen ir zen ast zen tokens zen clean This allows users to inspect different stage
AI 资讯
Building An Astro Blog
This article was originally published on hawksley.dev . I've owned the domain name hawksley.dev for a while now, but I've never done much with it aside from sending email. Over the weekend, I thought I might as well make good use of it and decided to create a blog. In the beginning, this site had a humble home page with some links to GitHub projects. A blog requires much more infrastructure for me to use it effectively. For one, it'd be great if I could just write my posts in Markdown and have them formatted by my project automatically. Having a look at the options available, the first that stood out was GitHub's Jekyll . It looked nice and had great integration with GitHub Pages, which I'm hosting with at the time of writing. However, it just felt too rigid. I needed something modern that I felt I could get my hands dirty with. Enter Astro. Why Astro In the grand scheme of things, the Astro framework is pretty new at just 5 years old. That hasn't prevented it from gaining popularity rapidly. It holds performance as a key design principle, anything that can be static will render statically. By default, it ships absolutely no JS to the browser, which felt perfect for my use case. I have no need for advertising or heavy tracking scripts weighing down my site. All I need is a place to write. Learning how to work with Astro was completely painless. I created a new GitHub repository and followed along with their very high-quality documentation to create a blog of my own. At the very end of it, I’d created a nice neat blog that loaded instantly and was easy to write for. I wasn't satisfied by using the tutorial's blog for my site, though, as it felt too cookie-cutter, and so I started again, now with confidence in the framework. The Design Decisions There were some definite design decisions I knew I wanted from the get-go. First-class light mode and dark mode support were a must. Plenty of blogs offered just one or the other, and after a bit of digging, it didn't seem tec
科技前沿
Emacs SVG Benchmark Reveals Gaming-Caliber Frame Rates
submitted by /u/misterchiply [link] [留言]
开发者
7 More Common Mistakes in Architecture Diagrams
submitted by /u/fagnerbrack [link] [留言]
AI 资讯
To handle performance issues, Integrate Redis with Spring Boot instead of scaling servers
A lot of developers rely on scaling servers to handle performance issues, but often, the real bottleneck is just fetching the exact same data from the database over and over again. If you are dealing with read-heavy APIs and want to reduce redundant database queries, Integrate Redis caching into a Spring Boot application using Spring Data Redis. A lot of developers manually manage cache states, but Spring’s cache abstraction makes it incredibly simple to handle with just a few annotations on your service layer. If you want to see the full implementation including the application properties configuration, the Redis Cache Manager setup, and the complete REST controller code, you can check out the full write-up here: Implementing Redis Caching in Spring Boot . submitted by /u/erdsingh24 [link] [留言]
开发者
Hacking Google with A.I. for $500,000
submitted by /u/ScottContini [link] [留言]
AI 资讯
WWDC 2026 - What's New in SwiftUI - A Developer's Breakdown
WWDC26 brought a substantial round of updates to SwiftUI — not a ground-up redesign, but a lot of small limitations removed, new APIs that were clearly driven by real-world pain points, and meaningful performance improvements. This post walks through every major announcement so you know exactly what's available and when to reach for it. Look and Feel: Liquid Glass and the 2027 Releases The most immediately visible change costs you zero code. Apps built with SwiftUI automatically pick up the updated Liquid Glass appearance on the 2027 OS releases. The glass tint responds to the new system-level Liquid Glass slider without any changes on your part. On iPad, windows now dim when inactive, reinforcing which window has focus — again, automatic. On Mac, custom interactive Liquid Glass elements respond more fluidly to the mouse pointer. There are a few opt-in refinements available when you want tighter control: Responding to active state — use the appearsActive environment value to reduce opacity on custom elements when the window is inactive: struct SidebarFooterView : View { @Environment (\ . appearsActive ) private var appearsActive var body : some View { MyAccountView () . opacity ( appearsActive ? 1 : 0.5 ) } } Menu bar icons — the menu bar now shows a minimal set of icons by default. Add .labelStyle(.titleAndIcon) to a specific menu item to make its icon visible: CommandMenu ( "Stickers" ) { Button { openStore () } label : { Label ( "Store" , systemImage : "bag.fill" ) . labelStyle ( . titleAndIcon ) } } Resizability on iPhone iPhone apps become resizable on iOS 27, which matters for iPhone Mirroring and running iPhone apps on iPad. Xcode 27's Live Previews now include resize handles so you can test this interactively without running on a device. If your app mixes UIKit and SwiftUI, check the session "Modernize your UIKit app" for specifics around screen geometry, size classes, and orientation handling. Toolbar APIs The toolbar has been a source of friction on smalle
AI 资讯
We added up the real cost of our 7-tool delivery stack. Licenses were 15% of it.
Every tool sprawl thread I read starts with license math, and license math is a decoy. Last quarter I added up what our seven-tool delivery stack actually cost us, and the subscriptions came to about 15% of the total. The other 85% never appears on an invoice, which is exactly why nobody budgets for it and nobody fixes it. Some background so you can judge whether my numbers transfer to your team. I spent years building automation in banking before running my own product team, so I am professionally allergic to process waste. Despite that, our stack had drifted into the usual shape: Jira for tickets, Confluence for docs, Lucidchart for architecture, TestRail for test cases, two spreadsheets doing unpaid overtime in the gaps, and an AI chatbot bolted on the side that had never seen any of it. The licenses for all of that, for six people, ran about $700 a month. Annoying. Not a crisis. And that is precisely why the "consolidate your tools" pitch dies in so many budget conversations. Saving a few hundred dollars a month does not justify a migration, and everyone in the room knows it. If licenses were the real cost, I would side with the skeptics. The audit: two weeks of logging every re-key So we measured the part nobody measures. For two weeks, everyone on the team logged every re-key: any moment a human moved or restated information that already existed in another tool. Copying acceptance criteria from Confluence into a Jira ticket. Updating TestRail because a story changed shape. Redrawing a Lucidchart flow that had drifted from the code. Reassembling a status update by hand from three tabs. Pasting project context into the chatbot, again, because it forgot everything since yesterday. The rules were strict so the number would survive scrutiny. Log transfer time only, not thinking time. Round down when unsure. If the same fact got re-keyed twice, log it twice, because it cost twice. Each entry went into a shared CSV with four columns, and this script turned it into th
AI 资讯
Still amazed every time I read this paper. What pros and cons do you think it would have against C++20 coroutines?
submitted by /u/germandiago [link] [留言]
AI 资讯
Dependency models in npm, Yarn, pnpm, Bun, and Deno
Compares npm, Yarn (Berry), pnpm, Bun, and Deno as different dependency models. submitted by /u/OtherwisePush6424 [link] [留言]
AI 资讯
Stop Vibe Coding. Start Spec-Driven Development with N45.AI
AI coding tools are changing how software gets built. Claude Code, Cursor, GitHub Copilot, Windsurf and other tools can generate code incredibly fast. For small tasks, they are already useful: write a component, explain a function, scaffold an endpoint, create a test, refactor a file. But after using AI in real projects, one thing becomes obvious: The problem is no longer code generation. The problem is engineering control. Most AI coding workflows still look like this: text idea -> prompt -> code -> fix -> prompt again -> more code -> lost context -> start over It feels fast at the beginning. Then the project grows. Requirements change. Architecture decisions disappear inside chat history. The AI forgets previous context. You start acting as product manager, architect, reviewer, QA, DevOps, and prompt engineer at the same time. That is not software engineering. That is vibe coding. ## Vibe coding works until it doesn't Direct AI coding is great when the task is isolated. Ask for a React component. Ask for a SQL query. Ask for a utility function. Ask for a unit test. No problem. But real software is not a collection of isolated snippets. Real software has: - business rules - architectural constraints - existing patterns - security concerns - database impact - deployment requirements - edge cases - regression risk - long-term maintenance When AI jumps directly from prompt to code, it often skips the thinking that should happen before implementation. The result may compile. But does it fit the architecture? Does it respect the domain? Does it create hidden technical debt? Does it solve the right problem? That is the gap we are trying to close with N45.AI. ## What is N45.AI? N45.AI is a framework that turns AI coding tools into a structured engineering workflow. It works with the tools developers already use, including Claude Code, Cursor, GitHub Copilot, and Windsurf. The idea is simple: Instead of treating AI as one generic assistant, N45.AI organizes the work like a
AI 资讯
I just launched 𝗙𝗮𝗰𝗲 𝗦𝗼𝗿𝘁 𝗦𝘁𝘂𝗱𝗶𝗼! 📸🤖
It is a privacy-first, local-first photo organizer powered by deep learning face recognition. It detects, embeds, and groups faces to organize your photos automatically—all 100% offline. 🔥 Highlight Features: ✅ 100% Local: No cloud APIs, no telemetry, no leaks. ✅ Deep Learning: Driven by OpenCV DNN (YuNet + SFace ONNX models). ✅ Smart Automation: Copies matches, partial matches, and individual profiles into organized folders, complete with ZIP archives and JSON reports. ✅ Standalone EXE: Run it on Windows instantly with zero dependencies. ✅ Dynamic UI: Fully responsive Tailwind dashboard with Dark/Light modes. Check out the repository, download the EXE, or contribute: 👉 https://github.com/Shaan-alpha/face-sort-studio Let me know what you think! ⭐ machinelearning #computervision #python #localfirst #privacy #developers #opensource #ai Internet access on first launch only (to fetch the AI models ~40-50mb)
AI 资讯
How I Ship 10x Faster with Claude Code: The 5-Layer Workflow System
After 8 months of daily Claude Code use, I've distilled my workflow into a 5-layer system. Each layer builds on the previous one. Skip one, and the whole thing falls apart. The Problem with Most Claude Code Users Most people use Claude Code like ChatGPT — open terminal, ask a question, close, repeat. The next day, they explain their project from scratch. Again. The symptom: 20% of every session is wasted on context re-establishment. The root cause: No project memory, no workflow discipline. Here's the system that fixed it for me. Layer 1: CLAUDE.md — Your Project's Memory Anchor This is the foundation. Without it, nothing else works. CLAUDE.md is a file at your project root. Claude reads it automatically at the start of every session. It tells Claude: What this project is (one sentence) The tech stack (specific technologies, not "Python web framework") The architecture (the big picture you'd need 3 files to understand) Unique conventions (not generic advice like "write tests") Quality priorities Bad CLAUDE.md (you've probably written this): # My Project A web application built with Python and FastAPI. ## Development - Write clean code - Add unit tests - Use Git This tells Claude nothing it doesn't already know. Good CLAUDE.md: # CLAUDE.md ## Project Overview Internal RAG knowledge base serving 500+ employees. ## Tech Stack FastAPI + LangChain + Milvus + PostgreSQL + Redis ## Commands - Start: `uvicorn app.main:app --reload --port 8080` - Test: `pytest -x --cov=app --cov-report=term-missing` ## Architecture Request flow: router → service → retriever → Milvus → generator → LLM API Key directories: - app/router/ - API layer - app/service/ - Business logic orchestration - app/retriever/ - Retrieval strategies (vector/BM25/hybrid) - app/generator/ - LLM calls and prompt management ## Key Conventions - All APIs return `{"data": ..., "error": null}` - Retrieval results MUST include source field - Milvus collection naming: `{env}_{doc_type}` The rule: Only write what's uniq
AI 资讯
How to Use Primitive Types in TypeScript: string, number, and boolean
TLDR TypeScript has 7 primitive types: string , number , boolean , null , undefined , bigint , and symbol . You use them to tell TypeScript what kind of value a variable holds. You write them in lowercase. TypeScript can often figure out the type for you. But knowing how each one works is key to writing safe and clear code. What Are Primitive Types? Primitive types are the simplest building blocks in TypeScript. Every piece of data in your program starts with one. They hold a single value. They are not objects. You cannot add methods or properties to them directly. TypeScript has 7 primitive types in total: Type What It Holds string Text like names, messages, or IDs number Any number: integers, decimals, negatives boolean Only true or false null An intentional empty value undefined A value that was never assigned bigint Very large whole numbers symbol A unique identifier value This article covers all 7. You will use string , number , and boolean the most in everyday TypeScript code. How to Use the string Type A string holds text. Use it for names, messages, emails, URLs, and any other text data. Basic string annotation let firstName : string = " Alice " ; let greeting : string = " Hello, world! " ; let empty : string = "" ; Three ways to write strings TypeScript supports the same three string styles as JavaScript: let single : string = ' Single quotes work fine ' ; let double : string = " Double quotes work too " ; let template : string = `Template literals with ${ firstName } ` ; Template literals (backticks) let you insert values inside a string with ${} . TypeScript checks the types of those inserted values too. let age : number = 30 ; let message : string = `I am ${ age } years old` ; // TypeScript checks that 'age' is compatible here What TypeScript catches with strings let name : string = " Alice " ; name = 42 ; // Error: Type 'number' is not assignable to type 'string'. name = true ; // Error: Type 'boolean' is not assignable to type 'string'. Once a variable
开发者
JEP 401 being merged into JDK 28?
submitted by /u/davidalayachew [link] [留言]
开发者
C# 14: The `field` Keyword — Cleaner Properties, Zero Boilerplate
C# 14: The field Keyword — Cleaner Properties, Zero Boilerplate Every C# developer has been there. You start with a clean auto-property, then requirements change and you need to add a tiny bit of validation. Suddenly that one-liner explodes into six lines of boilerplate — a private backing field, a getter that just returns it, a setter that assigns it. The logic is two words. The ceremony is everything else. C# 14 fixes this with the field keyword: a contextual keyword that refers to the compiler-synthesized backing field of a property, letting you write custom accessor logic without ever declaring an explicit field. The Problem: Boilerplate Tax on Simple Properties Auto-properties are one of C#'s best quality-of-life features. This is clean: public string Username { get ; set ; } But the moment you need to trim whitespace on assignment, that cleanness evaporates: private string _username = string . Empty ; public string Username { get => _username ; set => _username = value . Trim (); } You now have six lines — and four of them exist only to hold the shape of the pattern together. The backing field _username is not carrying any meaningful design weight. Its only job is to be a storage slot that Username uses privately. You already know the compiler creates one for auto-properties. You are just forced to make it visible so you can reference it. This is the boilerplate tax. You pay it every time you add even the smallest piece of logic to a property. Why field Exists The C# language team has discussed this friction for years. The challenge was finding syntax that is: Unambiguous — no conflict with existing identifiers Familiar — consistent with how value works in setters Scoped — only meaningful inside a property accessor The solution landed in C# 14: the contextual keyword field . Just like value refers to the incoming assignment in a setter, field refers to the hidden backing storage the compiler manages for the property. It is contextual, which means it only acts
AI 资讯
Your Agent Returns 200 and Lies. Verify Before You Trust
A success gate verifies an AI agent's claimed success before your system accepts it. SuccessGate runs three read-only checks — schema/contract, claim-vs-evidence against the actual tool-call trace, and an optional post-condition probe — and turns a silent 200 into an explicit REJECTED with reasons. It's stdlib Python, needs no API key, moves nothing, and ships with a self-test you run in one command. Here's the failure that started this for me. An agent in a CRM workflow reported {"status": "sent", ...} for an invoice. Clean run. Green dashboard. 200 OK. The invoice went to a customer id that wasn't on our allow-list — a near-miss hallucination the model was completely sure about. Nothing crashed. No exception, no stack trace. We found it days later, downstream, the expensive way. That's not a rare bug. It's the default failure mode of agents in production, and it has a name now: silent-success drift . Cycles' writeup put it bluntly — "200 OK Is the Most Dangerous Response in Production" : "The most dangerous failures look like success." And the measurements back it up. The Berkeley Function-Calling Leaderboard (BFCL v3) puts frontier-model structurally invalid tool calls at 2–5% even on clean benchmark prompts — higher in noisy production ( via Future AGI ). The arXiv paper Agent Behavioral Contracts reports that across 1,980 sessions , contracted agents caught 5.2–6.8 soft violations per session that uncontracted baselines missed entirely. So the question is not how do I see failures sooner . It's how do I stop accepting a success the agent never actually achieved. TL;DR A 200 and a "status": "done" are claims, not proof. Agents return both while doing the wrong thing — or nothing. Observability is tracking : it tells you a call happened. It can't tell you the result was correct. That's a control problem. verify() runs three checks before you accept success: (1) schema/contract (shape, types, enums/allow-list), (2) claim-vs-evidence (did the agent actually call th
AI 资讯
C3 0.8.1 released: Raiding the stdlib for bugs
submitted by /u/Nuoji [link] [留言]
开发者
The unwritten laws of software engineering
submitted by /u/fagnerbrack [link] [留言]
AI 资讯
You Don't Need Another Agent. You Need a Linter.
In my last post I complained — a lot — about product managers and how they made my life hell with vibe code. PS: apologies, manager, if you're reading this — but it's true. Now, I'm not here just to complain. There were a lot of learning opportunities too, like how to handle legacy / vibe code. Because at the end of the day, both are the same: no one knows how they work, but somehow they keep working. Touching them is like defusing a bomb — you never know how your change might cascade and break the core logic. The good news is that vibe code is much simpler than legacy. AI, in all its glory, tries to write perfect-looking code — proper function names, comments, the works — not like legacy code where a single function runs 500 lines, with spaghetti names all over that make no sense and comments that are out of date. And that makes it something I can actually handle. I still don't have a perfect, step-by-step playbook — but I've got pieces. The first one. The cheapest and the oldest one. The one the industry solved decades ago and the whole "AI built my app in a day" crowd somehow forgot exists. A linter. Yes, you heard me right. A linter. ESLint. Most people who've been in this industry already know it. It's the most boring, reliable tool in the box. But in an era where the answer to every problem is "add another AI," it's worth saying out loud why the boring tool still wins. What a linter actually is If you vibe-coded your way into this world, or you're new to web dev in general and have never heard the word "lint", here's the honest version. A linter is a set of rules you add to your repo. It reads your code without running it, checks it against those rules, and flags everything that's broken, sloppy, or about to bite you in production. The detail people get wrong: it's not a grep for bad words. A real linter parses your code into a syntax tree and actually reasons about its structure — what's imported, what's called, what's reachable, what types flow where. That's