Class Central is learner-supported. When you buy through links on our site, we may earn an affiliate commission.

YouTube

C++ as Assembly 2.0 - Hello Nim

code::dive conference via YouTube

Overview

Explore the potential of Nim as a powerful alternative to C++ in this comprehensive conference talk from code::dive 2019. Delve into Nim's advanced metaprogramming capabilities, whole-program compilation model, and seamless interoperability with C/C++. Learn about Nim's features, syntax, and performance advantages through practical examples and comparisons with C++. Gain insights into the evolving landscape of compiled and high-performance programming languages, and discover how Nim aims to improve developer productivity while maintaining top-tier performance. Examine the speaker's perspective on treating C++ as assembly and leveraging Nim as a more efficient tool for modern software development.

Syllabus

Intro
Hello echo "Hello World" # code
Discriminated Unions - Variants
Effect system - transitive
Distinct types - 'strong typedefs
What is an AST(Abstract Syntax Tree)
Meta-programming in Nim
Templates 2
Templates - pattern matching constructs
Dumping the AST of a code block
Macros - the explicit interface (low-level)
Getting the code to construct a code block
Executing the output from dumpAsten
quote doi' expressions - less verbose
HTML DSL (Domain Specific Language)
Protobuf implementation no external tool
What meta-programming gives us
Feature dump (Incomplete)
Nim compilation & runtime model
Nim procs to C/C++ (simplified)
Nim types to C/C++ (simplified)
Nim compilation to C/C++. a BIG win
Interfacing with C/C++
Nim's GC-time & memory use
Runtime - small binaries
Jester - a Sinatra-like web framework
On C++...
Clean slate - the C++ successor is here
Rust & Nim
Why programming languages matter and languages are
Popularity based on GitHub stars - Rust
Final Final thoughts

Taught by

code::dive conference

Reviews

Start your review of C++ as Assembly 2.0 - Hello Nim

Never Stop Learning.

Get personalized course recommendations, track subjects and courses with reminders, and more.

Someone learning on their laptop while sitting on the floor.